/* ANGSA Viterbo Aps — bozza del sito. Nessuna risorsa esterna: font di sistema, solo CSS/JS locale. */
:root {
  --notte: #0a2a4a;
  --blu: #0e86c8;
  --blu-2: #4ba6d2;
  --cielo: #94cae3;
  --ghiaccio: #eaf5fa;
  --bianco: #fff;
  --testo: #12324d;
  --muto: #4d6a80;
  --raggio: 22px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0; color: var(--testo); background: var(--bianco);
  font: 18px/1.65 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body.menu-aperto { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { line-height: 1.1; margin: 0 0 .5em; letter-spacing: -.02em; }
p { margin: 0 0 1em; }
em { font-style: normal; color: var(--blu); }
.contenitore { width: min(1140px, 100% - 40px); margin-inline: auto; }
.salta { position: absolute; left: -999px; top: 8px; background: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.salta:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--cielo); outline-offset: 3px; border-radius: 6px; }

/* ── Testata ── */
.testata {
  position: fixed; inset: 0 0 auto 0; z-index: 60; display: flex; align-items: center;
  justify-content: space-between; padding: 12px clamp(16px, 4vw, 40px);
  transition: background .4s, box-shadow .4s, padding .4s; color: #fff;
}
.testata.solida { background: rgba(255, 255, 255, .92); backdrop-filter: blur(12px); box-shadow: 0 2px 24px rgba(10, 42, 74, .12); color: var(--notte); padding-block: 6px; }
body.menu-aperto .testata { background: transparent; box-shadow: none; color: #fff; backdrop-filter: none; }
.marchio { display: flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 700; font-size: 1.05rem; }
.marchio img { height: 44px; width: auto; border-radius: 8px; background: #fff; padding: 2px 4px; }
.marchio small { font-weight: 500; opacity: .75; font-size: .85em; }
.azioni { display: flex; align-items: center; gap: 12px; }

.btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 13px 26px; border-radius: 999px;
  font-weight: 700; text-decoration: none; border: 2px solid transparent; font-size: 1rem;
  transition: transform .3s var(--ease), box-shadow .3s, background .3s, color .3s;
}
.btn:hover { transform: translateY(-3px); }
.btn-pieno { background: var(--blu); color: #fff; box-shadow: 0 10px 28px rgba(14, 134, 200, .4); }
.btn-pieno:hover { box-shadow: 0 16px 36px rgba(14, 134, 200, .55); }
.btn-vuoto { border-color: rgba(255, 255, 255, .7); color: #fff; }
.btn-vuoto:hover { background: #fff; color: var(--notte); }
.btn-accedi { padding: 9px 20px; border-color: currentColor; background: transparent; }
.testata:not(.solida) .btn-accedi:hover, body.menu-aperto .btn-accedi:hover { background: #fff; color: var(--notte); }
.testata.solida .btn-accedi { background: var(--blu); border-color: var(--blu); color: #fff; }

/* Pulsante hamburger che diventa una X */
.menu-btn { width: 48px; height: 48px; border-radius: 50%; border: 2px solid currentColor; background: transparent; color: inherit; cursor: pointer; position: relative; transition: transform .4s var(--ease); }
.menu-btn:hover { transform: rotate(90deg) scale(1.06); }
.menu-btn span { position: absolute; left: 12px; right: 12px; height: 2px; background: currentColor; border-radius: 2px; transition: transform .45s var(--ease), opacity .3s, top .45s var(--ease); }
.menu-btn span:nth-child(1) { top: 16px; }
.menu-btn span:nth-child(2) { top: 22px; right: 18px; }
.menu-btn span:nth-child(3) { top: 28px; }
.menu-btn[aria-expanded="true"] span:nth-child(1) { top: 22px; transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; transform: translateX(-12px); }
.menu-btn[aria-expanded="true"] span:nth-child(3) { top: 22px; transform: rotate(-45deg); }

/* ── Menù a tutto schermo con cerchio che si espande ── */
.menu { position: fixed; inset: 0; z-index: 50; visibility: hidden; transition: visibility 0s .8s; }
.menu.aperto { visibility: visible; transition-delay: 0s; }
.menu-cerchio {
  position: absolute; inset: 0; background: radial-gradient(circle at 30% 20%, #12609a, var(--notte) 70%);
  clip-path: circle(0 at calc(100% - 52px) 36px); transition: clip-path .9s var(--ease);
}
.menu.aperto .menu-cerchio { clip-path: circle(150% at calc(100% - 52px) 36px); }
.menu-corpo { position: relative; height: 100%; display: flex; flex-direction: column; justify-content: center; padding: 90px clamp(24px, 8vw, 120px) 40px; overflow-y: auto; }
.menu ul { list-style: none; margin: 0; padding: 0; }
.menu li { overflow: hidden; }
.menu li a {
  display: inline-flex; align-items: baseline; gap: 18px; color: #fff; text-decoration: none;
  font-size: clamp(2rem, 6.2vw, 4rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.2;
  transform: translateY(110%); transition: transform .8s var(--ease), color .3s; position: relative;
}
.menu.aperto li a { transform: none; }
.menu li:nth-child(1) a { transition-delay: .25s; } .menu li:nth-child(2) a { transition-delay: .3s; }
.menu li:nth-child(3) a { transition-delay: .35s; } .menu li:nth-child(4) a { transition-delay: .4s; }
.menu li:nth-child(5) a { transition-delay: .45s; } .menu li:nth-child(6) a { transition-delay: .5s; }
.menu li:nth-child(7) a { transition-delay: .55s; }
.menu li a i { font: 600 .9rem system-ui; color: var(--cielo); font-style: normal; letter-spacing: .1em; }
.menu li a::after { content: ""; position: absolute; left: 0; bottom: 4px; height: 3px; width: 100%; background: var(--cielo); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease); }
.menu li a:hover { color: var(--cielo); }
.menu li a:hover::after { transform: scaleX(1); }
.menu-nota { margin: 36px 0 0; color: var(--cielo); opacity: 0; transition: opacity .6s .9s; font-size: .95rem; }
.menu.aperto .menu-nota { opacity: .8; }

/* ── Hero ── */
.hero {
  position: relative; min-height: 100svh; display: flex; align-items: center; color: #fff; overflow: hidden;
  background: linear-gradient(160deg, #0a2a4a 0%, #0d5a94 55%, #0e86c8 100%); background-size: 160% 160%;
  animation: respiro 16s ease-in-out infinite alternate;
}
@keyframes respiro { to { background-position: 100% 100%; } }
.hero-sfondo { position: absolute; inset: 0; pointer-events: none; }
.pz { position: absolute; fill: rgba(255, 255, 255, .09); animation: fluttua 14s ease-in-out infinite alternate; will-change: transform; }
.pz1 { width: 160px; height: 160px; left: 6%; top: 18%; }
.pz2 { width: 90px; height: 90px; left: 38%; top: 12%; animation-duration: 11s; fill: rgba(148, 202, 227, .16); }
.pz3 { width: 240px; height: 240px; right: 4%; top: 14%; animation-duration: 18s; }
.pz4 { width: 110px; height: 110px; right: 30%; bottom: 24%; animation-duration: 12s; fill: rgba(148, 202, 227, .14); }
.pz5 { width: 70px; height: 70px; left: 14%; bottom: 26%; animation-duration: 9s; }
.pz6 { width: 180px; height: 180px; right: 12%; bottom: 14%; animation-duration: 20s; fill: rgba(255, 255, 255, .06); }
@keyframes fluttua { from { transform: translate(0, 0) rotate(-8deg); } to { transform: translate(22px, -34px) rotate(14deg); } }
.hero-testo { position: relative; width: min(1140px, 100% - 40px); margin-inline: auto; padding: 130px 0 190px; }
.sopra { text-transform: uppercase; letter-spacing: .22em; font-size: .85rem; font-weight: 700; color: var(--cielo); }
.titolone { font-size: clamp(2.8rem, 9.4vw, 7.6rem); font-weight: 800; letter-spacing: -.045em; line-height: .98; margin: 0 0 .35em; }
.riga { display: block; overflow: hidden; padding-bottom: .08em; }
.riga > span { display: inline-block; transform: translateY(110%); animation: sale 1.1s var(--ease) forwards; }
.riga:nth-child(2) > span { animation-delay: .15s; } .riga:nth-child(3) > span { animation-delay: .3s; }
@keyframes sale { to { transform: none; } }
.titolone em { color: var(--cielo); }
.sotto { font-size: clamp(1.1rem, 2.2vw, 1.4rem); max-width: 640px; color: #dbeefa; }
.cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.scorri { position: absolute; left: 50%; bottom: 120px; width: 28px; height: 46px; border: 2px solid rgba(255, 255, 255, .6); border-radius: 20px; transform: translateX(-50%); }
.scorri span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; background: #fff; border-radius: 2px; animation: rotella 1.8s ease-in-out infinite; }
@keyframes rotella { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(16px); } }
.onde { position: absolute; left: 0; bottom: -1px; width: 100%; height: 190px; }
.onda { transition: transform .2s linear; }
.o1 { fill: rgba(148, 202, 227, .35); animation: onda 11s ease-in-out infinite alternate; }
.o2 { fill: rgba(234, 245, 250, .6); animation: onda 8s ease-in-out infinite alternate-reverse; }
.o3 { fill: #fff; animation: onda 13s ease-in-out infinite alternate; }
@keyframes onda { from { transform: translateX(-3%); } to { transform: translateX(3%); } }

/* ── Sezioni ── */
.sezione { padding: clamp(70px, 11vw, 140px) 0; position: relative; }
.sezione.chiara { background: var(--ghiaccio); }
.sezione.scura { background: linear-gradient(160deg, var(--notte), #0d4a7c); color: #fff; }
.sezione.scura em { color: var(--cielo); }
.due { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 90px); align-items: center; }
.etichetta { text-transform: uppercase; letter-spacing: .2em; font-size: .8rem; font-weight: 800; color: var(--blu); margin-bottom: 1em; display: flex; align-items: center; gap: 12px; }
.etichetta::before { content: ""; width: 38px; height: 3px; background: currentColor; border-radius: 3px; }
.etichetta.chiara { color: var(--cielo); }
h2 { font-size: clamp(2rem, 5.2vw, 3.8rem); font-weight: 800; margin-bottom: .6em; }
.introduzione { font-size: 1.2rem; max-width: 680px; color: var(--muto); }
.scura .introduzione { color: #cfe5f3; }
.testo-bozza { font-size: .85rem; color: var(--muto); font-style: italic; }
.centro { text-align: center; }
.centro .introduzione, .centro .etichetta { margin-inline: auto; justify-content: center; }
.centro .cta { justify-content: center; }

/* Valori */
.valori { display: grid; gap: 16px; }
.valore { background: #fff; border-radius: var(--raggio); padding: 26px 28px 26px 96px; position: relative; box-shadow: 0 10px 40px rgba(10, 42, 74, .08); border: 1px solid #dbebf3; transition: transform .4s var(--ease), box-shadow .4s; }
.valore:hover { transform: translateX(-8px); box-shadow: 0 18px 50px rgba(14, 134, 200, .2); }
.valore svg { position: absolute; left: 24px; top: 24px; width: 52px; height: 52px; fill: var(--blu); transition: transform .6s var(--ease); }
.valore:hover svg { transform: rotate(180deg) scale(1.1); }
.valore h3 { font-size: 1.35rem; margin-bottom: .2em; }
.valore p { margin: 0; color: var(--muto); }

/* Passi del progetto */
.passi { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 50px; }
.passo { background: rgba(255, 255, 255, .07); border: 1px solid rgba(148, 202, 227, .25); border-radius: var(--raggio); padding: 34px 28px; backdrop-filter: blur(6px); transition: transform .4s var(--ease), background .4s; }
.passo:hover { transform: translateY(-10px); background: rgba(255, 255, 255, .13); }
.passo b { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 50%; background: var(--cielo); color: var(--notte); font-size: 1.4rem; margin-bottom: 20px; }
.passo h3 { font-size: 1.4rem; }
.passo p { margin: 0; color: #cfe5f3; }

/* Telefono */
.telefono-area { position: relative; display: grid; place-items: center; padding: 30px; }
.telefono { width: min(280px, 70vw); aspect-ratio: 9/18; border-radius: 40px; background: var(--notte); padding: 12px; box-shadow: 0 40px 80px rgba(10, 42, 74, .35); transform: rotate(-6deg); transition: transform .8s var(--ease); }
.telefono-area:hover .telefono { transform: rotate(0); }
.schermo { height: 100%; border-radius: 30px; background: var(--ghiaccio); padding: 16px 12px; display: flex; flex-direction: column; gap: 14px; }
.frase { height: 54px; background: #fff; border-radius: 14px; display: flex; gap: 8px; padding: 8px; }
.frase i { flex: 1; border-radius: 8px; background: var(--cielo); animation: batti 2.4s ease-in-out infinite; }
.frase i:nth-child(2) { animation-delay: .3s; } .frase i:nth-child(3) { animation-delay: .6s; }
@keyframes batti { 50% { transform: scale(.82); opacity: .6; } }
.griglia { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.griglia span { background: var(--c); border-radius: 14px; animation: tocca 5s ease-in-out infinite; }
.griglia span:nth-child(3n+2) { animation-delay: .8s; } .griglia span:nth-child(3n) { animation-delay: 1.6s; }
@keyframes tocca { 0%, 85%, 100% { transform: none; } 92% { transform: scale(.88); filter: brightness(1.25); } }
.pz-deco { position: absolute; width: 120px; height: 120px; right: 4%; bottom: 2%; fill: var(--cielo); opacity: .6; animation: fluttua 10s ease-in-out infinite alternate; }
.elenco { list-style: none; padding: 0; margin: 0 0 28px; }
.elenco li { padding-left: 34px; position: relative; margin-bottom: .5em; }
.elenco li::before { content: ""; position: absolute; left: 0; top: .35em; width: 20px; height: 20px; border-radius: 50%; background: var(--blu) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center/70% no-repeat; }

/* Novità ed eventi */
.due-col { display: grid; grid-template-columns: 1.3fr 1fr; gap: clamp(30px, 5vw, 70px); margin-top: 40px; }
.sottotitolo { font-size: 1.1rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muto); }
.notizia { display: grid; grid-template-columns: 150px 1fr; gap: 20px; background: #fff; border-radius: var(--raggio); padding: 14px; margin-bottom: 16px; box-shadow: 0 8px 30px rgba(10, 42, 74, .07); transition: transform .4s var(--ease), box-shadow .4s; }
.notizia:hover { transform: translateY(-6px); box-shadow: 0 18px 44px rgba(14, 134, 200, .2); }
.foto { border-radius: 14px; background: linear-gradient(135deg, var(--a), var(--b)); min-height: 110px; }
.notizia time { font-size: .8rem; font-weight: 700; color: var(--blu); text-transform: uppercase; letter-spacing: .1em; }
.notizia h4 { font-size: 1.25rem; margin: .2em 0 .3em; }
.notizia p { margin: 0; color: var(--muto); font-size: .95rem; line-height: 1.5; }
.evento { display: flex; align-items: center; gap: 18px; background: #fff; border-radius: var(--raggio); padding: 14px 20px 14px 14px; margin-bottom: 14px; transition: transform .4s var(--ease); }
.evento:hover { transform: translateX(10px); }
.data { width: 70px; height: 70px; border-radius: 18px; background: var(--blu); color: #fff; display: grid; place-content: center; text-align: center; line-height: 1; flex: none; }
.data b { font-size: 1.7rem; } .data span { font-size: .72rem; letter-spacing: .15em; margin-top: 4px; }
.evento h4 { margin: 0 0 .1em; font-size: 1.15rem; } .evento p { margin: 0; color: var(--muto); font-size: .95rem; }

/* Galleria */
.galleria { display: grid; grid-template-columns: repeat(6, 1fr); grid-auto-rows: 150px; gap: 14px; margin-top: 44px; }
.galleria figure { margin: 0; position: relative; overflow: hidden; border-radius: var(--raggio); background: linear-gradient(135deg, var(--a), var(--b)); display: grid; place-items: center; transition: transform .5s var(--ease); }
.galleria figure:hover { transform: scale(1.03) rotate(-.6deg); z-index: 2; }
.galleria svg { width: 70px; height: 70px; fill: rgba(255, 255, 255, .5); transition: transform .8s var(--ease); }
.galleria figure:hover svg { transform: rotate(120deg) scale(1.3); }
.galleria figcaption { position: absolute; left: 14px; bottom: 10px; color: #fff; font-weight: 700; font-size: .9rem; text-shadow: 0 1px 8px rgba(0, 0, 0, .3); }
.g1 { grid-column: span 3; grid-row: span 2; } .g2 { grid-column: span 3; } .g3 { grid-column: span 3; }
.g4 { grid-column: span 2; } .g5 { grid-column: span 4; }

/* Sostienici */
.sostieni { overflow: hidden; }
.sostieni::before, .sostieni::after { content: ""; position: absolute; width: 420px; height: 420px; border-radius: 50%; background: radial-gradient(circle, rgba(148, 202, 227, .25), transparent 70%); animation: fluttua 12s ease-in-out infinite alternate; }
.sostieni::before { left: -120px; top: -120px; } .sostieni::after { right: -140px; bottom: -140px; }
.sostieni .contenitore { position: relative; z-index: 1; }
.cf { display: inline-block; margin: 14px 0 6px; padding: 22px 38px; border-radius: var(--raggio); background: rgba(255, 255, 255, .1); border: 1px dashed var(--cielo); }
.cf span { display: block; font-size: .85rem; text-transform: uppercase; letter-spacing: .15em; color: var(--cielo); }
.cf b { font-size: clamp(2rem, 6vw, 3.4rem); letter-spacing: .06em; }

/* Contatti */
.schede-contatto { display: grid; gap: 14px; }
.scheda-c { background: var(--ghiaccio); border-radius: var(--raggio); padding: 22px 28px; border-left: 6px solid var(--blu); transition: transform .4s var(--ease); }
.scheda-c:hover { transform: translateX(8px); }
.scheda-c span { display: block; font-size: .8rem; text-transform: uppercase; letter-spacing: .15em; color: var(--muto); }
.scheda-c b { font-size: 1.3rem; }

/* Piede */
.piede { background: var(--notte); color: #cfe5f3; padding: 50px 0; font-size: .95rem; }
.piede-in { display: grid; grid-template-columns: auto 1fr; gap: 30px; align-items: center; }
.piede img { border-radius: 10px; background: #fff; padding: 4px 8px; }
.piede p { margin: 0; } .piccolo { grid-column: 1 / -1; font-size: .8rem; opacity: .7; }

/* Comparsa allo scorrimento */
.js .rv { opacity: 0; transform: translateY(36px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--ritardo, 0s); }
.js .rv.in { opacity: 1; transform: none; }

/* ── Adattamento ── */
@media (max-width: 860px) {
  .due, .due-col, .passi { grid-template-columns: 1fr; }
  .galleria { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 140px; }
  .galleria figure { grid-column: span 1 !important; grid-row: span 1 !important; }
  .galleria .g1 { grid-column: span 2 !important; grid-row: span 2 !important; }
  .notizia { grid-template-columns: 100px 1fr; }
  .marchio span { display: none; }
  .scorri { display: none; }
  .hero-testo { padding-bottom: 150px; }
  .piede-in { grid-template-columns: 1fr; }
}

/* Per chi preferisce meno movimento (importante per un pubblico sensibile agli stimoli) */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
  .riga > span { transform: none; }
  .js .rv { opacity: 1; transform: none; }
  .menu li a { transform: none; }
}

/* Fascia con la frase che scorre */
.fascia { background: var(--cielo); color: var(--notte); overflow: hidden; padding: 26px 0; }
.fascia-nastro { display: flex; align-items: center; gap: 36px; width: max-content; animation: nastro 38s linear infinite; }
.fascia-nastro span { font-size: clamp(2rem, 5vw, 3.6rem); font-weight: 800; letter-spacing: -.03em; white-space: nowrap; }
.fascia-nastro svg { width: 44px; height: 44px; fill: var(--blu); flex: none; }
@keyframes nastro { to { transform: translateX(-50%); } }
/* Chiusura */
.chiusura { background: var(--ghiaccio); text-align: center; padding: clamp(80px, 12vw, 150px) 20px; }
.chiusura p { margin: 0; font-size: clamp(2.2rem, 7vw, 5.5rem); font-weight: 800; letter-spacing: -.04em; line-height: 1.05; }
@media (prefers-reduced-motion: reduce) { .fascia-nastro { animation: none; flex-wrap: wrap; width: auto; justify-content: center; } }

/* Attività */
.attivita { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 36px 0 14px; }
.att { background: #fff; border-radius: var(--raggio); padding: 24px; border: 1px solid #dbebf3; transition: transform .4s var(--ease), box-shadow .4s; }
.att:hover { transform: translateY(-6px); box-shadow: 0 16px 40px rgba(14, 134, 200, .2); }
.att svg { width: 34px; height: 34px; fill: var(--blu); margin-bottom: 10px; transition: transform .6s var(--ease); }
.att:hover svg { transform: rotate(180deg); }
.att h3 { font-size: 1.15rem; margin-bottom: .3em; }
.att p { margin: 0; color: var(--muto); font-size: .95rem; line-height: 1.5; }
@media (max-width: 860px) { .attivita { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .attivita { grid-template-columns: 1fr; } }

/* ── Palette dei pezzi di puzzle e delle lettere (come nella locandina) ── */
:root { --p1: #e8408f; --p2: #1aa7e0; --p3: #27b36a; --p4: #f6a21e; --p5: #ef4b3f; --p6: #7cc242; }
.hero-sfondo .pz { opacity: .55; }
.hero-sfondo .pz1 { fill: var(--p1); } .hero-sfondo .pz2 { fill: var(--p4); } .hero-sfondo .pz3 { fill: var(--p2); }
.hero-sfondo .pz4 { fill: var(--p3); } .hero-sfondo .pz5 { fill: var(--p5); } .hero-sfondo .pz6 { fill: var(--p6); }
.valore:nth-child(1) svg, .att:nth-child(1) svg, .fascia-nastro svg:nth-of-type(1) { fill: var(--p1); }
.valore:nth-child(2) svg, .att:nth-child(2) svg, .fascia-nastro svg:nth-of-type(2) { fill: var(--p2); }
.valore:nth-child(3) svg, .att:nth-child(3) svg, .fascia-nastro svg:nth-of-type(3) { fill: var(--p3); }
.att:nth-child(4) svg, .fascia-nastro svg:nth-of-type(4) { fill: var(--p4); }
.att:nth-child(5) svg { fill: var(--p5); } .att:nth-child(6) svg { fill: var(--p6); }
.pz-deco { fill: var(--p4); opacity: .9; }

/* Scritta a lettere colorate */
.l { font-style: normal; display: inline-block; background: var(--g); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; }
.l.sp { width: .28em; }
.titolone { text-transform: uppercase; font-weight: 900; letter-spacing: .01em; line-height: .96; font-size: clamp(2.5rem, 8vw, 6.6rem); }
.titolone .riga { padding-bottom: .04em; }
.titolone .r2 { font-size: 1.28em; margin-left: 1.1em; }
.titolone .r3 { font-size: .74em; }
.titolone .r4 { font-size: 1.32em; margin-left: .7em; }
.fascia { background: #fff; border-block: 1px solid #dbebf3; }
.fascia-nastro span { text-transform: uppercase; font-weight: 900; }
.chiusura p { text-transform: uppercase; font-weight: 900; max-width: 14ch; margin-inline: auto; }

/* Notizie ed eventi separati */
.notizie { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 36px; }
.notizie .notizia { grid-template-columns: 1fr; margin: 0; }
.notizie .foto { min-height: 170px; }
.eventi { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 36px; }
.eventi .evento { margin: 0; background: var(--ghiaccio); }
.locandina { margin: 0; background: #fff; border-radius: var(--raggio); padding: 10px; box-shadow: 0 30px 70px rgba(0, 0, 0, .35); transform: rotate(-2deg); transition: transform .6s var(--ease); }
.locandina:hover { transform: rotate(0) scale(1.02); }
.locandina img { width: 100%; height: auto; border-radius: 14px; }
@media (max-width: 860px) { .notizie, .eventi { grid-template-columns: 1fr; } .titolone .r2 { margin-left: .5em; } .titolone .r4 { margin-left: .3em; } }
@media (max-width: 860px) and (min-width: 521px) { .notizie .notizia { grid-template-columns: 160px 1fr; } .notizie .foto { min-height: 110px; } }
.menu li a { font-size: clamp(1.7rem, 5vw, 3.2rem); }
.menu li:nth-child(8) a { transition-delay: .6s; }

/* Card attività apribili + finestra con la descrizione */
.att { cursor: pointer; position: relative; }
.att-piu { display: inline-block; margin-top: 12px; font-size: .85rem; font-weight: 700; color: var(--blu); opacity: 0; transform: translateX(-6px); transition: opacity .3s, transform .3s var(--ease); }
.att:hover .att-piu, .att:focus-visible .att-piu { opacity: 1; transform: none; }
@media (hover: none) { .att-piu { opacity: 1; transform: none; } }
.modale { border: 0; padding: 0; width: min(640px, calc(100% - 32px)); max-height: calc(100svh - 48px); border-radius: 26px; background: #fff; color: var(--testo); box-shadow: 0 40px 100px rgba(10, 42, 74, .45); overflow: auto; padding: 38px clamp(24px, 5vw, 44px) 34px; }
.modale[open] { animation: apre .45s var(--ease); }
.modale::backdrop { background: rgba(10, 42, 74, .55); backdrop-filter: blur(5px); animation: sfuma .35s; }
@keyframes apre { from { opacity: 0; transform: translateY(24px) scale(.96); } }
@keyframes sfuma { from { opacity: 0; } }
.modale h3 { font-size: clamp(1.5rem, 4vw, 2.1rem); margin: 8px 0 .6em; padding-right: 40px; }
.modale-pz { width: 44px; height: 44px; fill: var(--p4); display: block; }
.modale-x { position: absolute; right: 16px; top: 14px; width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--ghiaccio); color: var(--notte); font-size: 1.6rem; line-height: 1; cursor: pointer; transition: transform .3s var(--ease), background .3s; }
.modale-x:hover { background: var(--cielo); transform: rotate(90deg); }
.modale-testo .lead { font-size: 1.2rem; font-weight: 700; color: var(--blu); }
.modale-testo ul { padding-left: 1.2em; } .modale-testo li { margin-bottom: .25em; }
.modale-testo .nota { font-size: .85rem; color: var(--muto); border-top: 1px solid #dbebf3; padding-top: 14px; margin-top: 18px; }
.modale-testo a { color: var(--blu); word-break: break-all; }

/* ── "Scopri di più": appare al passaggio del mouse (sempre visibile su touch) ── */
.att-piu { display: none; }
.att { cursor: default; }
.scopri-link { display: inline-block; margin-top: 12px; padding: 0; border: 0; background: none; font: inherit; font-size: .9rem; font-weight: 800; color: var(--blu); text-decoration: none; cursor: pointer; opacity: 0; transform: translateX(-8px); transition: opacity .3s, transform .35s var(--ease); }
.att:hover .scopri-link, .att:focus-within .scopri-link, .evento:hover .scopri-link, .evento:focus-within .scopri-link,
.notizia:hover .scopri-link, .notizia:focus-within .scopri-link, .scopri-link.visibile, .scopri-link:focus-visible { opacity: 1; transform: none; }
.scopri-link:hover { text-decoration: underline; text-underline-offset: 4px; }
@media (hover: none) { .scopri-link { opacity: 1; transform: none; } }
.scopri-link.visibile { margin-top: 4px; }

/* ── Carosello orizzontale (notizie, eventi, foto nelle finestre) ── */
.carosello { position: relative; }
.track { display: flex; gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; padding: 10px 4px 26px; scrollbar-width: none; overscroll-behavior-x: contain; }
.track::-webkit-scrollbar { display: none; }
.track > * { scroll-snap-align: start; flex: 0 0 auto; }
.freccia { position: absolute; top: 45%; z-index: 3; width: 48px; height: 48px; border-radius: 50%; border: 0; background: #fff; color: var(--notte); box-shadow: 0 8px 26px rgba(10, 42, 74, .25); font-size: 1.4rem; line-height: 1; cursor: pointer; transition: transform .3s var(--ease), opacity .3s, background .3s; }
.freccia:hover { background: var(--blu); color: #fff; transform: scale(1.1); }
.freccia.indietro { left: -14px; } .freccia.avanti { right: -14px; }
.freccia[hidden] { display: none; }
.freccia:disabled { opacity: 0; pointer-events: none; }

.carosello .notizia { width: min(350px, 82vw); display: flex; flex-direction: column; margin: 0; padding: 14px 14px 18px; grid-template-columns: none; }
.carosello .notizia .foto { min-height: 170px; margin-bottom: 14px; }
.carosello .notizia .nt { flex: 1; }
.carosello .evento { width: min(340px, 82vw); flex-direction: column; align-items: stretch; margin: 0; padding: 16px 18px 16px 16px; background: var(--ghiaccio); gap: 0; }
.carosello .evento:hover { transform: translateY(-6px); }
.evt { display: flex; align-items: center; gap: 18px; }

/* Foto nelle finestre */
.modale-foto { margin-bottom: 20px; border-radius: 18px; overflow: hidden; }
.modale-foto .track { padding: 0; gap: 0; }
.modale-foto .track > i { flex: 0 0 100%; aspect-ratio: 16 / 10; background: linear-gradient(135deg, var(--a), var(--b)); display: grid; place-items: end start; padding: 14px 18px; font-style: normal; }
.modale-foto b { color: #fff; font-size: .9rem; text-shadow: 0 1px 8px rgba(0, 0, 0, .3); }
.modale-foto .freccia { top: calc(50% - 24px); }
.modale-foto .freccia.indietro { left: 10px; } .modale-foto .freccia.avanti { right: 10px; }
.modale-testo .btn { margin-top: 6px; }
@media (max-width: 860px) { .freccia.indietro { left: 2px; } .freccia.avanti { right: 2px; } }
.modale-testo a.btn { color: #fff; word-break: normal; text-decoration: none; }
.carosello .evento { background: #fff; }
#notizie .notizia { background: var(--ghiaccio); box-shadow: none; }

.scheda-c b a { text-decoration: none; }
.scheda-c b a:hover { color: var(--blu); text-decoration: underline; text-underline-offset: 4px; }
.social { display: inline-flex; align-items: center; gap: 12px; justify-self: start; padding: 12px 22px 12px 14px; border-radius: 999px; background: #1877f2; color: #fff; font-weight: 700; text-decoration: none; transition: transform .3s var(--ease), box-shadow .3s; }
.social:hover { transform: translateY(-3px); box-shadow: 0 12px 28px rgba(24, 119, 242, .4); }
.social svg { background: rgba(255, 255, 255, .18); border-radius: 50%; padding: 7px; box-sizing: content-box; }
