/* Cirillico (30/09/2026): i font del design non hanno le lettere cirilliche; il secondo font della pila le ha e il browser lo scarica solo se in pagina ce ne sono. */
/* ============================================================
   SVEAHOST · LAYOUT 3 "EDITORIAL" (Gabriele) — stampo del generatore.
   Nato dallo stampo storico (stesse classi: nav, hero, mission-section,
   feature…) con un refresh editoriale: bianco, accento rosso, Fraunces
   + Inter. Il foglio è quello di Gabriele, a strati (WOW, WOW 2, WOW 3,
   passata mobile…), adattato al contratto della piattaforma
   (templates/README.md) con modifiche sul posto e la sezione finale
   "CONTRATTO DELLA PIATTAFORMA":
   - gli stati iniziali delle animazioni esistono solo quando app.js è
     partito (classi che mette lui: .reveal, .wipe, .is-live, .film,
     .is-flow, html.fx) → senza JavaScript tutto è visibile;
   - nessun testo nel CSS: le scritte decorative le crea app.js dal
     testo vero, i suggerimenti arrivano da data-hint;
   - la galleria è una griglia piatta (.gallery-grid) col ritmo di
     Gabriele a giro di 12; il menu del telefono è la stessa lista.
   ============================================================ */

:root {
  --bg: #EFEBE2;
  --bg-2: #E5DFD2;
  --bg-dark: #1A1916;
  --ink: #0A0A09;
  --ink-2: #2A2825;
  --muted: #6B6862;
  --line: rgba(10,10,9,0.14);
  --line-strong: rgba(10,10,9,0.32);
  /* gli ACCENTI stanno tutti nel blocco PALETTE in fondo al foglio */

  --font-display: 'Fraunces', 'Lora', Georgia, serif;
  --font-sans: 'Inter', system-ui, sans-serif;

  --pad-section: clamp(5rem, 10vw, 9rem);
  --container: 1280px;
  --gutter: clamp(1.5rem, 4vw, 3rem);

  --ease: cubic-bezier(0.65, 0.05, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; background: var(--bg); }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 17px;
  line-height: 1.6;
  position: relative;
}

body::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.035;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.9 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  mix-blend-mode: multiply;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
::selection { background: var(--accent-fill); color: var(--on-accent); }

.container { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }

/* ============ TYPOGRAPHY ============ */
.display {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.02em;
}
.display em { font-style: italic; }

.eyebrow {
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 28px;
  height: 1px;
  background: currentColor;
}

/* ============ NAV ============ */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1.25rem var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background 0.4s, backdrop-filter 0.4s, border-color 0.4s, padding 0.3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled,
.nav.solid {
  background: rgba(239, 235, 226, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: var(--line);
  padding-top: 1rem;
  padding-bottom: 1rem;
}
.nav-brand {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.02em;
  line-height: 1;
}
.nav-links {
  display: flex;
  gap: 2.5rem;
  list-style: none;
}
.nav-links a {
  font-size: 14px;
  font-weight: 500;
  position: relative;
  padding: 4px 0;
  transition: color 0.3s;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 1px;
  width: 0;
  background: currentColor;
  transition: width 0.4s var(--ease-out);
}
.nav-links a:hover::after,
.nav-links a[aria-current="page"]::after { width: 100%; }
.nav-links a[aria-current="page"] { color: var(--accent); }
.nav-cta {
  font-size: 13px;
  font-weight: 500;
  padding: 11px 22px;
  border: 1px solid var(--ink);
  border-radius: 100px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: background 0.3s, color 0.3s;
}
.nav-cta:hover { background: var(--ink); color: var(--bg); }
.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
}
.nav-toggle svg { width: 22px; height: 22px; }
@media (max-width: 900px) {
  .nav-links, .nav-cta { display: none; }
  .nav-toggle { display: flex; }
  .nav.menu-open .nav-links {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg);
    padding: 2rem var(--gutter);
    gap: 1.5rem;
    border-bottom: 1px solid var(--line);
    z-index: 100;
  }
}

/* ============ BUTTONS ============ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 16px 26px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent-fill), #fff 16%) 0%, var(--accent-fill) 70%);
  color: var(--on-accent);
  border-radius: 100px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.20),
    0 8px 20px color-mix(in srgb, var(--accent-fill) 40%, transparent),
    0 3px 8px rgba(10, 10, 9, 0.16);
  transition: transform 0.5s var(--ease-out), background 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
.btn-primary svg {
  width: 16px;
  height: 16px;
  transition: transform 0.5s var(--ease-out);
}
.btn-primary:hover svg { transform: translate(3px, -3px); }
.btn-primary:hover {
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent-fill-2), #fff 14%) 0%, var(--accent-fill-2) 72%);
}
.btn-primary:not(.mission-btn):hover {
  transform: translateY(-3px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.26),
    0 18px 38px color-mix(in srgb, var(--accent-fill) 50%, transparent),
    0 5px 14px rgba(10, 10, 9, 0.20);
}
.btn-primary:not(.mission-btn):active {
  transform: translateY(-1px);
  box-shadow:
    inset 0 2px 6px rgba(10, 10, 9, 0.30),
    0 4px 12px rgba(10, 10, 9, 0.18);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 22px;
  border: 1px solid color-mix(in srgb, var(--ink) 55%, transparent);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  background: color-mix(in srgb, var(--bg), #fff 35%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.6),
    0 4px 12px rgba(10, 10, 9, 0.08);
  transition: transform 0.5s var(--ease-out), background 0.5s var(--ease-out), color 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out), border-color 0.5s var(--ease-out);
}
.btn-outline:hover {
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent-fill), #fff 16%) 0%, var(--accent-fill) 70%);
  color: var(--on-accent);
  border-color: var(--accent-fill);
  transform: translateY(-3px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 18px 34px color-mix(in srgb, var(--accent-fill) 45%, transparent),
    0 5px 14px rgba(10, 10, 9, 0.16);
}
.btn-outline:active {
  transform: translateY(-1px);
  box-shadow:
    inset 0 2px 5px rgba(10, 10, 9, 0.22),
    0 4px 12px rgba(10, 10, 9, 0.16);
}
.btn-outline svg { width: 14px; height: 14px; transition: transform 0.5s var(--ease-out); }
.btn-outline:hover svg { transform: translateX(4px); }

/* ============ HERO ============ */
.hero {
  min-height: 92vh;
  padding: 10rem var(--gutter) 4rem;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow: hidden;
  max-width: var(--container);
  margin: 0 auto;
}
.hero-eyebrow {
  margin-bottom: 2.5rem;
}
.hero-title {
  font-size: clamp(2.5rem, 7vw, 6.5rem);
  margin: 0 auto 2rem;
  max-width: 18ch;
}
/* Le parole del titolo le crea app.js (<span class="word">, con --i): senza
   JavaScript il titolo è testo normale, già visibile. */
.hero-title .word {
  display: inline-block;
  transform: translateY(110%);
  opacity: 0;
}
.hero.loaded .hero-title .word {
  animation: rise-in 1.1s var(--ease-out) forwards;
  animation-delay: calc(0.15s + var(--i, 0) * 80ms);
}
@keyframes rise-in {
  to { transform: translateY(0); opacity: 1; }
}

.hero-sub {
  font-size: clamp(1.05rem, 1.4vw, 1.2rem);
  line-height: 1.55;
  max-width: 38rem;
  margin: 0 auto;
  color: var(--ink-2);
}
/* Entrata del sottotitolo e del bottone: solo con JavaScript (html.js) e
   comunque a tempo — l'animazione finisce visibile da sola. */
html.js .hero-sub, html.js .hero-actions {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 1s var(--ease-out) 0.9s forwards;
}
html.js .hero-actions { animation-delay: 1.05s; }
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }
.hero-actions { margin-top: 2.5rem; display: flex; justify-content: center; }
/* il bottone (che l'originale non aveva) non deve finire addosso al "scorri" della lastra */
.hero:has(.hero-actions) { padding-bottom: 6rem; }

/* ============ PAGE HEADER (inner pages) ============ */
.page-header {
  padding: 11rem var(--gutter) 5rem;
  text-align: center;
  border-bottom: 1px solid var(--line);
  max-width: var(--container);
  margin: 0 auto;
}
.page-header .eyebrow { margin-bottom: 2.5rem; }
.page-header h1 {
  font-size: clamp(2.6rem, 8vw, 7rem);
  line-height: 0.98;
  letter-spacing: -0.025em;
  margin: 0 auto 2rem;
  max-width: 22ch;
}
.page-header h1 em { color: var(--accent); }
.page-header h1 .word {
  display: inline-block;
  transform: translateY(110%);
  opacity: 0;
}
.page-header.loaded .word {
  animation: rise-in 1s var(--ease-out) forwards;
  animation-delay: calc(0.3s + var(--i, 0) * 80ms);
}
.page-header .lead {
  font-size: clamp(1.1rem, 1.5vw, 1.35rem);
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 42rem;
  margin: 0 auto;
}

/* ============ SECTION (generic) ============ */
section { padding: var(--pad-section) var(--gutter); }
.section-inner { max-width: var(--container); margin: 0 auto; }

/* Reveal animation */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1.1s var(--ease-out), transform 1.1s var(--ease-out);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}
.reveal.stagger > * {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1s var(--ease-out), transform 1s var(--ease-out);
}
.reveal.in.stagger > * { opacity: 1; transform: translateY(0); }
.reveal.in.stagger > *:nth-child(1) { transition-delay: 0.1s; }
.reveal.in.stagger > *:nth-child(2) { transition-delay: 0.25s; }
.reveal.in.stagger > *:nth-child(3) { transition-delay: 0.4s; }
.reveal.in.stagger > *:nth-child(4) { transition-delay: 0.55s; }
.reveal.in.stagger > *:nth-child(5) { transition-delay: 0.7s; }

/* Services list: faster reveal (scoped, doesn't affect other pages) */
.services-list.reveal { transition-duration: 0.5s; }
.services-list.reveal.stagger > * { transition-duration: 0.5s; }
.services-list.reveal.in.stagger > *:nth-child(1) { transition-delay: 0.04s; }
.services-list.reveal.in.stagger > *:nth-child(2) { transition-delay: 0.10s; }
.services-list.reveal.in.stagger > *:nth-child(3) { transition-delay: 0.16s; }
.services-list.reveal.in.stagger > *:nth-child(4) { transition-delay: 0.22s; }
.services-list.reveal.in.stagger > *:nth-child(n+5) { transition-delay: 0.28s; }

/* ============ MISSION CTA — EXPANDING (scroll-driven, no pin) ============ */
.mission-section {
  padding: clamp(4rem, 8vw, 7rem) var(--gutter);
  background: var(--bg);
  position: relative;
}

.mission-sticky {
  display: flex;
  align-items: center;
  justify-content: center;
}

.mission-card {
  --p: 0;
  width: calc(min(1080px, 92vw) + (min(96vw, 1500px) - min(1080px, 92vw)) * var(--p));
  padding:
    clamp(3.5rem, calc(6vw + 2.5vw * var(--p)), 8rem)
    clamp(1.75rem, calc(4vw + 2vw * var(--p)), 5rem);
  border-radius: calc(40px - 12px * var(--p));
  background: color-mix(in srgb, var(--bg-2), var(--accent) calc(var(--p) * 100%));
  text-align: center;
  position: relative;
  box-shadow:
    0 calc(30px * (1 - var(--p))) calc(80px * (1 - var(--p))) rgba(10, 10, 9, calc(0.10 * (1 - var(--p)))),
    0 calc(6px * (1 - var(--p))) calc(20px * (1 - var(--p))) rgba(10, 10, 9, calc(0.06 * (1 - var(--p))));
}

.mission-card-inner {
  max-width: 70rem;
  margin: 0 auto;
}

.mission-card .eyebrow {
  margin-bottom: 2rem;
  justify-content: center;
  color: color-mix(in srgb, var(--muted), var(--bg) calc(var(--p) * 85%));
}

.mission-card h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.2rem, calc(5vw + 1.4vw * var(--p)), 5.4rem);
  line-height: 1;
  letter-spacing: -0.02em;
  max-width: 20ch;
  margin: 0 auto 1.5rem;
  color: color-mix(in srgb, var(--ink), var(--bg) calc(var(--p) * 100%));
}
.mission-card h2 em {
  color: color-mix(in srgb, var(--accent), var(--accent-glow) calc(var(--p) * 100%));
}

.mission-card p {
  font-size: clamp(1rem, calc(1.3vw + 0.3vw * var(--p)), 1.35rem);
  line-height: 1.55;
  max-width: 40rem;
  margin: 0 auto 2.5rem;
  color: color-mix(in srgb, var(--ink-2), var(--bg) calc(var(--p) * 90%));
}

.mission-btn {
  background: color-mix(in srgb, var(--ink), var(--bg) calc(var(--p) * 100%));
  color: color-mix(in srgb, var(--bg), var(--ink) calc(var(--p) * 100%));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    0 8px 20px rgba(10, 10, 9, 0.20),
    0 3px 8px rgba(10, 10, 9, 0.14);
  transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
.mission-btn:hover {
  background: color-mix(in srgb, var(--cta-btn-hover), var(--bg) calc(var(--p) * 60%));
  color: var(--on-cta-hover);
  transform: translateY(-3px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 18px 38px rgba(10, 10, 9, 0.30),
    0 5px 14px rgba(10, 10, 9, 0.20);
}
.mission-btn:active {
  transform: translateY(-1px);
  box-shadow:
    inset 0 2px 6px rgba(10, 10, 9, 0.26),
    0 4px 12px rgba(10, 10, 9, 0.18);
}

@media (prefers-reduced-motion: reduce) {
  .mission-card { --p: 0 !important; }
}

/* Inverted variant: starts green, expands to light (opposite of default) */
.mission-card--inverted {
  background: color-mix(in srgb, var(--accent), var(--bg-2) calc(var(--p) * 100%));
}
.mission-card--inverted .eyebrow {
  color: color-mix(in srgb, var(--bg), var(--muted) calc(var(--p) * 85%));
}
.mission-card--inverted h2 {
  color: color-mix(in srgb, var(--bg), var(--ink) calc(var(--p) * 100%));
}
.mission-card--inverted h2 em {
  color: color-mix(in srgb, var(--accent-glow), var(--accent) calc(var(--p) * 100%));
}
.mission-card--inverted p {
  color: color-mix(in srgb, var(--bg), var(--ink-2) calc(var(--p) * 90%));
}
.mission-card--inverted .mission-btn {
  background: color-mix(in srgb, var(--bg), var(--ink) calc(var(--p) * 100%));
  color: color-mix(in srgb, var(--ink), var(--bg) calc(var(--p) * 100%));
}
.mission-card--inverted .mission-btn:hover {
  background: color-mix(in srgb, var(--bg), var(--accent) calc(var(--p) * 60%));
  color: var(--ink);
}

/* ============ ADVANTAGES — 3 colonne uguali (pattern DecaRoy) ============ */
.advantages-head {
  text-align: center;
  max-width: 40rem;
  margin: 0 auto clamp(3rem, 6vw, 5rem);
  position: relative;
}
.advantages-head .eyebrow {
  margin-bottom: 1.5rem;
  justify-content: center;
  position: relative;
  z-index: 1;
}
.advantages-head h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
  position: relative;
  z-index: 1;
}
.advantages-head h2 em { color: var(--accent); }
.advantages-head p {
  font-size: clamp(1rem, 1.2vw, 1.1rem);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 34rem;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.advantages-head-mark {
  position: absolute;
  top: 4.2rem;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(3.4rem, 7.6vw, 8rem);
  color: var(--accent);
  opacity: 0.055;
  letter-spacing: -0.04em;
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  z-index: 0;
  -webkit-mask-image: linear-gradient(90deg, transparent, black 18%, black 82%, transparent);
  mask-image: linear-gradient(90deg, transparent, black 18%, black 82%, transparent);
}

.advantages-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(2.5rem, 4vw, 4rem);
}
.advantage {
  background: transparent;
  border: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
  position: relative;
  text-decoration: none;
  color: inherit;
  transition: transform 0.5s var(--ease-out);
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
}
@media (hover: hover) {
  .advantage:hover {
    transform: translateY(-4px);
  }
}
.advantage-media {
  aspect-ratio: 4/5;
  width: 100%;
  border-radius: clamp(14px, 1.6vw, 22px);
  overflow: hidden;
  background: var(--bg);
  position: relative;
  transform: translateZ(0);
}
.advantage-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.03);
  transition: transform 1s var(--ease-out);
}
@media (hover: hover) {
  .advantage:hover .advantage-media img { transform: scale(1.05); }
}
.advantage-media::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 65%, rgba(10,10,9,0.18));
}
.advantage h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.7rem, 2.4vw, 2.2rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0.25rem 0 0;
}
.advantage h3 em { font-style: italic; color: var(--accent); }
.advantage p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink-2);
  max-width: 32ch;
  margin: 0;
}

/* Floating CTA: small circle in default state, expands to rounded panel on hover.
   In expanded state: italic display label bottom-left, arrow bottom-right,
   rounded stripes top-left, all floating inside the bottom half of the image. */
.advantage-cta {
  position: absolute;
  bottom: clamp(1rem, 1.5vw, 1.4rem);
  right: clamp(1rem, 1.5vw, 1.4rem);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--bg);
  color: var(--ink);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding: 17px;
  gap: 0;
  z-index: 2;
  overflow: hidden;
  box-shadow: 0 6px 24px rgba(10, 10, 9, 0.18);
  transition:
    width 0.6s var(--ease-out),
    height 0.6s var(--ease-out),
    bottom 0.6s var(--ease-out),
    right 0.6s var(--ease-out),
    border-radius 0.6s var(--ease-out),
    background 0.4s var(--ease-out),
    color 0.4s,
    box-shadow 0.4s,
    padding 0.6s var(--ease-out);
}
.advantage-cta-label {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  letter-spacing: -0.015em;
  line-height: 1;
  white-space: nowrap;
  max-width: 0;
  opacity: 0;
  transition: max-width 0.6s var(--ease-out), opacity 0.4s var(--ease-out);
}
.advantage-cta > svg:last-child {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  transition: width 0.5s var(--ease-out), height 0.5s var(--ease-out);
}
.advantage-cta-decor {
  position: absolute;
  top: clamp(1.75rem, 2.8vw, 2.8rem);
  left: clamp(1.75rem, 2.8vw, 2.8rem);
  width: clamp(52px, 6vw, 76px);
  height: auto;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.45s var(--ease-out), transform 0.55s var(--ease-out);
  pointer-events: none;
}
.advantage-cta-decor rect {
  fill: currentColor;
  opacity: 0.45;
}
@media (hover: hover) {
  .advantage:hover .advantage-cta-decor {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.3s;
  }
  .advantage:hover .advantage-cta {
    width: calc(100% - 2 * clamp(1rem, 1.5vw, 1.4rem));
    height: 52%;
    bottom: clamp(1rem, 1.5vw, 1.4rem);
    right: clamp(1rem, 1.5vw, 1.4rem);
    border-radius: clamp(14px, 1.6vw, 22px);
    background: linear-gradient(to top, rgba(10, 10, 9, 0.55), rgba(10, 10, 9, 0.12) 50%, rgba(10, 10, 9, 0.04));
    -webkit-backdrop-filter: blur(14px) saturate(1.1);
    backdrop-filter: blur(14px) saturate(1.1);
    color: var(--bg);
    box-shadow: 0 10px 32px rgba(10, 10, 9, 0.22);
    padding: clamp(1.4rem, 2.4vw, 2.4rem);
  }
  .advantage:hover .advantage-cta-label {
    max-width: 20rem;
    opacity: 1;
    transition-delay: 0.2s;
  }
  .advantage:hover .advantage-cta > svg:last-child {
    width: 26px;
    height: 26px;
  }
}

/* Touch/scroll-triggered expansion (JS adds .is-expanded on viewport entry) */
.advantage.is-expanded {
  transform: translateY(-4px);
}
.advantage.is-expanded .advantage-media img { transform: scale(1.05); }
.advantage.is-expanded .advantage-cta-decor {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.3s;
}
.advantage.is-expanded .advantage-cta {
  width: calc(100% - 2 * clamp(1rem, 1.5vw, 1.4rem));
  height: 52%;
  bottom: clamp(1rem, 1.5vw, 1.4rem);
  right: clamp(1rem, 1.5vw, 1.4rem);
  border-radius: clamp(14px, 1.6vw, 22px);
  background: linear-gradient(to top, rgba(10, 10, 9, 0.55), rgba(10, 10, 9, 0.12) 50%, rgba(10, 10, 9, 0.04));
  -webkit-backdrop-filter: blur(14px) saturate(1.1);
  backdrop-filter: blur(14px) saturate(1.1);
  color: var(--bg);
  box-shadow: 0 10px 32px rgba(10, 10, 9, 0.22);
  padding: clamp(1.4rem, 2.4vw, 2.4rem);
}
.advantage.is-expanded .advantage-cta-label {
  max-width: 20rem;
  opacity: 1;
  transition-delay: 0.2s;
}
.advantage.is-expanded .advantage-cta > svg:last-child {
  width: 26px;
  height: 26px;
}

@media (max-width: 900px) {
  .advantages-grid { grid-template-columns: 1fr; gap: clamp(2rem, 5vw, 3rem); }
  .advantage-media { aspect-ratio: 5/4; }
}

/* ============ FEATURE SECTION (editorial card overlap on image) ============ */
section.feature {
  padding: clamp(5rem, 10vw, 9rem) var(--gutter);
  overflow: hidden;
}
.feature-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 0;
  max-width: var(--container);
  margin: 0 auto;
  position: relative;
}
.feature.mirror .feature-grid {
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
}
.feature.mirror .feature-media { order: 2; }
.feature.mirror .feature-text { order: 1; }

.feature-media {
  position: relative;
  aspect-ratio: 4/5;
  overflow: hidden;
  border-radius: clamp(18px, 2vw, 28px);
  background: var(--bg-2);
  transform: translateZ(0);
  -webkit-mask-image: -webkit-radial-gradient(white, black);
}
.feature-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.04);
  transition: transform 1.4s var(--ease-out);
}
.feature-media:hover img { transform: scale(1.04); }
.feature-media::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 55%, rgba(10, 10, 9, 0.22));
}

.feature-badge {
  position: absolute;
  bottom: 1.25rem;
  left: 1.25rem;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px 9px 12px;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid color-mix(in srgb, var(--ink) 8%, transparent);
  border-radius: 100px;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
  font-weight: 500;
  z-index: 2;
}
.feature-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.feature-text {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  background: var(--bg);
  padding: clamp(2rem, 3.5vw, 3.25rem);
  border-radius: clamp(18px, 2vw, 28px);
  box-shadow: 0 24px 60px rgba(10, 10, 9, 0.10);
  margin-left: clamp(-12vw, -7vw, -3rem);
  z-index: 2;
  position: relative;
  max-width: none;
}
.feature.mirror .feature-text {
  margin-left: 0;
  margin-right: clamp(-12vw, -7vw, -3rem);
}

.feature-lede {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 0.25rem;
}
.feature-num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--accent);
  line-height: 1;
}
.feature-rule {
  width: 32px;
  height: 1px;
  background: color-mix(in srgb, var(--ink) 25%, transparent);
}
.feature-lede .eyebrow {
  color: var(--ink-2);
}
.feature-lede .eyebrow::before { display: none; }

.feature-text h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 4.5vw, 3.6rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
}
.feature-text h2 em { color: var(--accent); }
.feature-text p {
  font-size: clamp(1rem, 1.3vw, 1.15rem);
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 32rem;
}
.feature-text .btn-outline,
.feature-text .btn-primary {
  align-self: flex-start;
  margin-top: 0.5rem;
}

@media (max-width: 900px) {
  section.feature { padding: clamp(3rem, 8vw, 5rem) 0; }
  .feature-grid,
  .feature.mirror .feature-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .feature-media,
  .feature.mirror .feature-media {
    aspect-ratio: 4/5;
    border-radius: clamp(18px, 4vw, 24px);
    order: 1;
    margin: 0 var(--gutter);
  }
  .feature-text,
  .feature.mirror .feature-text {
    order: 2;
    margin: clamp(-5rem, -10vw, -3rem) calc(var(--gutter) + 0.75rem) 0;
    padding: clamp(1.75rem, 5vw, 2.5rem);
    background: var(--bg);
    border-radius: clamp(18px, 4vw, 24px);
    box-shadow: 0 -10px 32px rgba(10, 10, 9, 0.10);
    max-width: none;
    width: auto;
  }
}

/* ============ ABOUT PAGE — INTRO (editorial 2-col) ============ */
.about-intro {
  max-width: 76rem;
  margin: 0 auto clamp(3rem, 6vw, 5rem);
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(2rem, 5vw, 6rem);
  align-items: center;
  text-align: left;
  position: relative;
}
.about-intro-head {
  position: relative;
}
.about-intro-head h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 1;
  letter-spacing: -0.025em;
  position: relative;
  z-index: 1;
}
.about-intro-head h2 em { color: var(--accent); }

/* Decorative chapter mark — huge italic "01" sitting behind the heading */
.about-chapter-mark {
  position: absolute;
  top: -0.3em;
  right: -0.1em;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(8rem, 14vw, 14rem);
  line-height: 0.85;
  color: var(--accent);
  opacity: 0.08;
  pointer-events: none;
  user-select: none;
  letter-spacing: -0.04em;
  z-index: 0;
}

.about-intro-body {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding-bottom: 0.25rem;
}
.about-intro-lead {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.25rem, 2vw, 1.65rem);
  line-height: 1.3;
  letter-spacing: -0.005em;
  color: var(--ink);
  border-left: 2px solid var(--accent);
  padding: 0.1em 0 0.15em clamp(1rem, 1.8vw, 1.5rem);
  margin: 0;
}
.about-intro-body p:not(.about-intro-lead) {
  font-size: clamp(0.98rem, 1.15vw, 1.08rem);
  line-height: 1.7;
  color: var(--ink-2);
  margin: 0;
  padding-left: clamp(1rem, 1.8vw, 1.5rem);
}

.about-intro-cta {
  align-self: flex-start;
  margin-top: 0.25rem;
  margin-left: clamp(1rem, 1.8vw, 1.5rem);
}

/* Decorative divider — accent line + accent dot, between lead and body */
.about-intro-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-left: clamp(1rem, 1.8vw, 1.5rem);
  margin: 0.25rem 0;
}
.about-intro-divider::before {
  content: '';
  width: 32px;
  height: 1px;
  background: var(--line-strong);
}
.about-intro-divider::after {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

@media (max-width: 900px) {
  .about-intro {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 2rem;
  }
  .about-chapter-mark {
    font-size: clamp(6rem, 22vw, 9rem);
    top: -0.25em;
    right: -0.05em;
    opacity: 0.07;
  }
}

.about-showcase {
  --p: 0;
  margin: clamp(3rem, 6vw, 5rem) 0;
  width: calc(min(64rem, 86vw) + (min(96rem, 96vw) - min(64rem, 86vw)) * var(--p));
  max-width: 96vw;
  aspect-ratio: 21/9;
  border-radius: calc(20px + 12px * var(--p));
  overflow: hidden;
  background: var(--bg-2);
  position: relative;
  left: 50%;
  transform: translate3d(-50%, 0, 0);
  -webkit-mask-image: -webkit-radial-gradient(white, black);
}

@media (prefers-reduced-motion: reduce) {
  .about-showcase { --p: 1 !important; }
}
.about-showcase img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.04);
  transition: transform 1.4s var(--ease-out);
}
.about-showcase:hover img { transform: scale(1.03); }
@media (max-width: 720px) {
  .about-showcase { aspect-ratio: 4/3; border-radius: 18px; }
}

.about-mission {
  max-width: 48rem;
  margin: 0 auto;
  padding: clamp(3rem, 6vw, 5rem) 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: center;
}
.about-mission .eyebrow { margin-bottom: 1.5rem; justify-content: center; }
.about-mission h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}
.about-mission h3 em { color: var(--accent); }
.about-mission p {
  font-size: clamp(1rem, 1.2vw, 1.1rem);
  line-height: 1.7;
  color: var(--ink-2);
}

.about-pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(2rem, 3vw, 3rem);
  padding-top: clamp(3rem, 6vw, 5rem);
}
.pillar {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding-bottom: clamp(2rem, 4vw, 3rem);
}
.pillar-media {
  width: 100%;
  aspect-ratio: 4/3;
  border-radius: 18px;
  overflow: hidden;
  background: var(--bg-2);
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 1;
  transform: translateZ(0);
  -webkit-mask-image: -webkit-radial-gradient(white, black);
}
.pillar-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.9) contrast(1.04);
  transition: transform 1s var(--ease-out);
}
.pillar:hover .pillar-media img { transform: scale(1.04); }
.pillar-num {
  position: absolute;
  left: 50%;
  top: 72%;
  transform: translate(-110%, -20%);
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(8rem, 16vw, 14rem);
  color: var(--accent);
  opacity: 0.08;
  line-height: 0.85;
  letter-spacing: -0.04em;
  pointer-events: none;
  user-select: none;
  z-index: 0;
  margin: 0;
}
.pillar h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.3rem, 2vw, 1.6rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
}
.pillar p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 22rem;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
@media (max-width: 768px) {
  .about-pillars { grid-template-columns: 1fr; }
}

.about-cta {
  text-align: center;
  margin-top: clamp(4rem, 8vw, 6rem);
  padding: clamp(3rem, 6vw, 5rem) 0;
  border-top: 1px solid var(--line);
}

/* Mission CTA — fullscreen variant: snaps open when pinned, snaps closed when leaving */
@property --p {
  syntax: '<number>';
  inherits: true;
  initial-value: 0;
}
/* La scena a tutto schermo (sezione alta, card appiccicata che si allarga con
   lo scroll) esiste solo con app.js (.is-live): senza, è una card normale. */
.mission-section--full {
  position: relative;
}
.mission-section--full.is-live {
  padding: 0;
  min-height: 160vh;
}
.mission-section--full.is-live > .mission-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.mission-card--full {
  --p: 0;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(10, 10, 9, 0.10), 0 6px 20px rgba(10, 10, 9, 0.06);
}
.mission-section--full.is-live .mission-card--full {
  width: calc(min(1080px, 92vw) + (100vw - min(1080px, 92vw)) * var(--p));
  height: calc(clamp(360px, 52vh, 560px) + (100vh - clamp(360px, 52vh, 560px)) * var(--p));
  border-radius: calc(40px - 40px * var(--p));
  display: flex;
  align-items: center;
  justify-content: center;
}
.mission-card--full .mission-card-inner {
  flex: 0 1 auto;
  width: 100%;
  max-width: 70rem;
}
.about-cta h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}
.about-cta h3 em { color: var(--accent); }
.about-cta p {
  font-size: clamp(1rem, 1.2vw, 1.1rem);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 36rem;
  margin: 0 auto 2rem;
}

/* ============ HERO FEATURE — immersive tile w/ glass card overlay ============ */
section.hero-feature {
  padding: clamp(5rem, 9vw, 8rem) clamp(1rem, 2.5vw, 2.5rem) clamp(3rem, 5vw, 5rem);
}
.hero-feature-tile {
  position: relative;
  border-radius: clamp(20px, 2vw, 32px);
  overflow: hidden;
  isolation: isolate;
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  min-height: clamp(540px, 78vh, 780px);
  background: var(--bg-2);
  transform: translateZ(0);
  -webkit-mask-image: -webkit-radial-gradient(white, black);
}
.hero-feature-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  filter: saturate(0.95) contrast(1.05);
}
.hero-feature-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(10, 10, 9, 0.45) 0%, rgba(10, 10, 9, 0.15) 45%, transparent 75%),
    linear-gradient(0deg, rgba(10, 10, 9, 0.25), transparent 55%);
  z-index: 1;
  pointer-events: none;
}
.hero-feature-card {
  position: absolute;
  top: clamp(1.5rem, 3vw, 2.5rem);
  bottom: clamp(1.5rem, 3vw, 2.5rem);
  left: clamp(1.5rem, 3vw, 2.5rem);
  width: clamp(340px, 42%, 560px);
  z-index: 2;
  padding: clamp(2rem, 3.2vw, 3rem);
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  -webkit-backdrop-filter: blur(18px) saturate(1.1);
  backdrop-filter: blur(18px) saturate(1.1);
  border: 1px solid color-mix(in srgb, white 20%, transparent);
  border-radius: 22px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.25rem;
  box-shadow: 0 30px 60px -30px rgba(10, 10, 9, 0.25);
}
/* Eyebrow lede with accent dot */
.hero-feature-lede {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-sans);
  font-size: 11px;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--ink);
  align-self: flex-start;
}
.hero-feature-lede .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  flex: 0 0 auto;
}

/* Titolo: la parola in evidenza (accent) in corsivo rosso, come la seconda riga dell'originale */
.hero-feature-title {
  font-family: var(--font-display);
  font-weight: 400;
  margin: 0;
  font-size: clamp(2.2rem, 3.6vw, 3.4rem);
  letter-spacing: -0.025em;
  line-height: 0.98;
}
.hero-feature-title em { font-style: italic; color: var(--accent); }

/* Body with highlighted phrase */
.hero-feature-body {
  font-size: clamp(1rem, 1.15vw, 1.1rem);
  line-height: 1.6;
  color: var(--ink-2);
  margin: 0;
}
.hero-feature-body em {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--accent);
  font-weight: 400;
  font-size: 1.12em;
  letter-spacing: -0.005em;
}

/* Integrated CTA — editorial footer bar with circular accent ripple on hover */
.hero-feature-cta {
  margin: auto calc(-1 * clamp(2rem, 3.2vw, 3rem)) calc(-1 * clamp(2rem, 3.2vw, 3rem));
  padding: clamp(1.2rem, 1.8vw, 1.7rem) clamp(2rem, 3.2vw, 3rem);
  border-top: 1px solid color-mix(in srgb, var(--ink) 9%, transparent);
  background: transparent;
  color: var(--ink);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  text-decoration: none;
  position: relative;
  isolation: isolate;
  transition: color 0.55s var(--ease-out);
}
.hero-feature-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--accent-fill);
  clip-path: circle(0% at calc(100% - 2.5rem) 50%);
  transition: clip-path 0.7s var(--ease-out);
  z-index: -1;
}
.hero-feature-cta:hover { color: var(--on-accent); }
.hero-feature-cta:hover::before {
  clip-path: circle(150% at calc(100% - 2.5rem) 50%);
}

.hero-feature-cta-label,
.hero-feature-cta-arrow {
  position: relative;
  z-index: 1;
}

.hero-feature-cta-label {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.2rem, 1.55vw, 1.45rem);
  letter-spacing: -0.005em;
  line-height: 1;
}

.hero-feature-cta-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}
.hero-feature-cta-arrow svg {
  width: 26px;
  height: 26px;
}

/* Stagger entry animation tied to the section's .reveal.in state (.reveal la mette app.js) */
.hero-feature.reveal .hero-feature-card > * {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1s var(--ease-out), transform 1s var(--ease-out);
}
.hero-feature.reveal.in .hero-feature-card > * {
  opacity: 1;
  transform: translateY(0);
}
.hero-feature.reveal.in .hero-feature-lede           { transition-delay: 0.15s; }
.hero-feature.reveal.in .hero-feature-title          { transition-delay: 0.30s; }
.hero-feature.reveal.in .hero-feature-body           { transition-delay: 0.5s; }
.hero-feature.reveal.in .hero-feature-cta            { transition-delay: 0.65s; }

@media (max-width: 900px) {
  .hero-feature-tile {
    min-height: 0;
    aspect-ratio: auto;
    display: flex;
    flex-direction: column;
    background: transparent;
  }
  .hero-feature-img {
    position: relative;
    height: clamp(280px, 50vh, 480px);
  }
  .hero-feature-overlay { display: none; }
  .hero-feature-card {
    position: relative;
    top: auto;
    bottom: auto;
    left: auto;
    width: auto;
    margin: -3rem 1rem 0;
    max-width: none;
    background: var(--bg);
    border-color: var(--line);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}

/* ============ SERVICES INTRO — section opener above the services list ============ */
section.services-intro-section {
  padding: clamp(4rem, 7vw, 7rem) var(--gutter) clamp(2rem, 4vw, 4rem);
  overflow: hidden;
}
.services-intro {
  max-width: var(--container);
  margin: 0 auto;
}
.services-intro-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.5rem;
  max-width: 46rem;
  margin: 0 auto;
  padding: clamp(2rem, 4vw, 3rem) 0;
}
/* Live pulse indicator above the eyebrow */
.services-intro-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  position: relative;
  flex: 0 0 auto;
}
/* niente anelli pulsanti: il punto resta fermo, come un segno tipografico */

.services-intro-card .eyebrow {
  margin-bottom: 0.75rem;
  justify-content: center;
}
.services-intro-card h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.2rem, 4.4vw, 3.8rem);
  line-height: 1.02;
  letter-spacing: -0.022em;
  margin: 0;
}
.services-intro-card h2 em { color: var(--accent); font-style: italic; }
.services-intro-card p {
  font-size: clamp(1.05rem, 1.3vw, 1.2rem);
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0;
  max-width: 38rem;
}

/* ============ SERVICES PAGE ============ */
.services-list {
  display: flex;
  flex-direction: column;
  gap: clamp(3rem, 5vw, 4rem);
  max-width: var(--container);
  margin: 0 auto;
}
.service-item {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) minmax(280px, 380px);
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: center;
  padding-bottom: clamp(3rem, 5vw, 4rem);
  border-bottom: 1px solid var(--line);
}
.service-item:last-child { border-bottom: none; }
.service-num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  color: var(--accent);
  line-height: 1;
  align-self: start;
  padding-top: 0.5rem;
}
.service-content { display: flex; flex-direction: column; gap: 1rem; }
.service-content .eyebrow { margin-bottom: 0.25rem; }
.service-content h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.service-content h3 em { color: var(--accent); }
.service-content p {
  font-size: clamp(1rem, 1.2vw, 1.1rem);
  line-height: 1.65;
  color: var(--ink-2);
  max-width: 50rem;
}

/* Service CTA — editorial pill-link with accent arrow circle, row-hover responsive */
.service-cta {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-top: 0.5rem;
  align-self: flex-start;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  position: relative;
  padding: 8px 0;
  transition: color 0.4s var(--ease-out);
}
.service-cta::before {
  content: '';
  position: absolute;
  left: 0;
  right: 52px; /* don't underline the arrow circle */
  bottom: 0;
  height: 1px;
  background: color-mix(in srgb, var(--ink) 18%, transparent);
}
.service-cta::after {
  content: '';
  position: absolute;
  left: 0;
  right: 52px;
  bottom: 0;
  height: 1px;
  background: var(--accent);
  transform-origin: left center;
  transform: scaleX(0);
  transition: transform 0.55s var(--ease-out);
}
.service-cta-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid currentColor;
  transition: background 0.4s var(--ease-out), color 0.4s var(--ease-out), border-color 0.4s var(--ease-out), transform 0.45s var(--ease-out);
  flex: 0 0 auto;
}
.service-cta-arrow svg {
  width: 13px;
  height: 13px;
  transition: transform 0.45s var(--ease-out);
}

/* Hover — triggered on CTA itself OR anywhere on the service item */
.service-cta:hover,
.service-item:hover .service-cta { color: var(--accent); }
.service-cta:hover::after,
.service-item:hover .service-cta::after { transform: scaleX(1); }
.service-cta:hover .service-cta-arrow,
.service-item:hover .service-cta-arrow {
  background: var(--accent-fill);
  color: var(--on-accent);
  border-color: var(--accent-fill);
}
.service-cta:hover .service-cta-arrow svg,
.service-item:hover .service-cta-arrow svg { transform: translate(2px, -2px); }
.service-item:hover .service-media img { transform: scale(1.04); }
.service-item:hover .service-num { color: var(--accent-2); }
.service-num { transition: color 0.4s var(--ease-out); }
.service-media {
  aspect-ratio: 4/5;
  border-radius: 20px;
  overflow: hidden;
  background: var(--bg-2);
  position: relative;
  transform: translateZ(0);
  -webkit-mask-image: -webkit-radial-gradient(white, black);
}
.service-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.04);
  transition: transform 1s var(--ease-out);
}
.service-media:hover img { transform: scale(1.04); }

@media (max-width: 900px) {
  .service-item {
    grid-template-columns: 56px 1fr;
    grid-template-areas:
      "num content"
      "media media";
    row-gap: 2rem;
  }
  .service-num { grid-area: num; }
  .service-content { grid-area: content; }
  .service-media { grid-area: media; aspect-ratio: 16/10; }
}

/* ============ CONTACT PAGE ============ */
.contact-page {
  padding-top: 9rem;
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(3rem, 6vw, 6rem);
  align-items: start;
  max-width: var(--container);
  margin: 0 auto;
}
.contact-text .eyebrow { margin-bottom: 1.5rem; }
.contact-text h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.5rem, 6vw, 5rem);
  line-height: 1;
  letter-spacing: -0.025em;
  margin-bottom: 1.5rem;
}
.contact-text h1 em { color: var(--accent); }
.contact-text p {
  font-size: clamp(1.05rem, 1.3vw, 1.2rem);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 32rem;
  margin-bottom: 2.5rem;
}

.contact-list {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  list-style: none;
}
.contact-item {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}
.contact-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}
.contact-value {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2vw, 1.8rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.015em;
  transition: color 0.3s;
}
a.contact-value:hover { color: var(--accent); }
.contact-value em { font-style: italic; }
.contact-hours {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 1.5rem;
  margin-top: 4px;
}
.contact-hours span {
  font-size: 14px;
  color: var(--ink-2);
}
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }

/* ============ CONTACT FORM ============ */
.contact-form-section {
  padding: clamp(5rem, 9vw, 8rem) var(--gutter);
  background: var(--bg-2);
  border-top: 1px solid var(--line);
  margin-top: clamp(5rem, 9vw, 8rem);
}
.contact-form-inner {
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: clamp(3rem, 6vw, 6rem);
  align-items: start;
}
.contact-form-head .eyebrow { margin-bottom: 1.5rem; }
.contact-form-head h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}
.contact-form-head h2 em { color: var(--accent); }
.contact-form-head p {
  font-size: clamp(1rem, 1.2vw, 1.1rem);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 28rem;
}

/* i campi arrivano dal contenuto (quanti e quali): due colonne, il messaggio a tutta riga */
.contact-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  position: relative;
}
.form-field.full, .contact-form .form-submit { grid-column: 1 / -1; }
.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.form-field label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}
.form-field input,
.form-field textarea {
  font-family: var(--font-sans);
  font-size: 1rem;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.9rem 1.1rem;
  transition: border-color 0.25s, box-shadow 0.25s;
  width: 100%;
}
.form-field textarea {
  resize: vertical;
  min-height: 9rem;
  line-height: 1.55;
}
.form-field input::placeholder,
.form-field textarea::placeholder {
  color: var(--muted);
  opacity: 0.7;
}
.form-field input:hover,
.form-field textarea:hover {
  border-color: var(--line-strong);
}
.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(var(--ring-rgb), 0.12);
}
.form-submit {
  justify-self: start;
  margin-top: 0.5rem;
}

@media (max-width: 900px) {
  .contact-form-inner { grid-template-columns: 1fr; }
  .contact-form { grid-template-columns: 1fr; }
}

/* ============ CONTACT MAP ============ */
.contact-map-section {
  padding: clamp(4rem, 8vw, 7rem) var(--gutter);
}
.contact-map-inner {
  max-width: var(--container);
  margin: 0 auto;
}
.contact-map-head {
  margin-bottom: clamp(2rem, 4vw, 3rem);
  max-width: 36rem;
}
.contact-map-head .eyebrow { margin-bottom: 1.25rem; }
.contact-map-head h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1;
  letter-spacing: -0.02em;
}
.contact-map-head h2 em { color: var(--accent); }
.contact-map {
  border-radius: clamp(16px, 2vw, 28px);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-2);
}
.contact-map iframe {
  display: block;
  width: 100%;
  height: clamp(360px, 55vh, 560px);
  filter: grayscale(0.2) contrast(0.95);
}

/* ============ GALLERY HERO ============ */
.gallery-hero {
  min-height: 100vh;
  padding: clamp(8rem, 14vw, 12rem) var(--gutter) clamp(3rem, 5vw, 5rem);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.gallery-hero .eyebrow {
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}
/* il titolo della galleria è spesso il nome dell'attività (più parole): corpo un po'
   più piccolo dell'originale ("Galleria"), righe bilanciate */
.gallery-hero-title {
  font-size: clamp(3.4rem, 11vw, 12rem);
  line-height: 0.92;
  letter-spacing: -0.03em;
  margin: 0;
  color: var(--ink);
  max-width: 12ch;
  text-wrap: balance;
  overflow-wrap: anywhere;
}
.gallery-hero-title em {
  font-style: italic;
  color: var(--accent);
}
.gallery-hero-sub {
  margin-top: clamp(2rem, 4vw, 3rem);
  font-size: clamp(1rem, 1.3vw, 1.2rem);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 36rem;
}
.gallery-hero-scroll {
  position: absolute;
  bottom: clamp(2rem, 4vw, 3rem);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  animation: gallery-scroll-bob 2.5s var(--ease) infinite;
}
.gallery-hero-scroll::before { content: attr(data-hint); }
.gallery-hero-scroll svg {
  width: 18px;
  height: 18px;
}
@keyframes gallery-scroll-bob {
  0%, 100% { transform: translate(-50%, 0); opacity: 0.6; }
  50% { transform: translate(-50%, 8px); opacity: 1; }
}

/* ============ GALLERY SECTIONS ============
   Le sei composizioni di Gabriele (grande + due impilate · tutta larghezza ·
   dittico sfalsato · tre · alta + larga · tutta larghezza) in UNA griglia piatta
   (.gallery-grid > figure): il ritmo si ripete ogni 12 foto con nth-child, e gli
   ultimi gruppi incompleti si chiudono senza buchi. Regge da 3 a 40 foto. */
.gallery-sections {
  padding: clamp(4rem, 8vw, 7rem) var(--gutter);
  max-width: 1500px;
  margin: 0 auto;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(0.75rem, 2vw, 1.75rem);
}

.gallery-tile {
  position: relative;
  overflow: hidden;
  border-radius: clamp(14px, 1.6vw, 22px);
  background: var(--bg-2);
  margin: 0;
  min-width: 0;
  aspect-ratio: 4/5;
}
.gallery-tile img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.2s var(--ease-out);
}
.gallery-tile:hover img { transform: scale(1.04); }

.gallery-tile figcaption {
  position: absolute;
  z-index: 2;
  left: clamp(1rem, 2vw, 1.75rem);
  bottom: clamp(1rem, 2vw, 1.75rem);
  right: clamp(1rem, 2vw, 1.75rem);
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--bg);
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.4);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.45s var(--ease-out), transform 0.45s var(--ease-out);
  pointer-events: none;
}
.gallery-tile:hover figcaption, .gallery-tile:focus-visible figcaption { opacity: 1; transform: translateY(0); }
.gallery-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to top, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0) 50%);
  opacity: 0;
  transition: opacity 0.45s var(--ease-out);
  pointer-events: none;
}
.gallery-tile:has(figcaption):hover::after { opacity: 1; }

.gallery-tile .cap-num {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-style: italic;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}
.gallery-tile .cap-title {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  line-height: 1.3;
}

/* Telefono e tablet: due colonne, una foto larga ogni cinque; una foto che
   resterebbe sola nella riga diventa larga. */
@media (max-width: 900px) {
  .gallery-tile:nth-child(5n+1),
  .gallery-tile:nth-child(5n+2):last-child,
  .gallery-tile:nth-child(5n+4):last-child { grid-column: 1 / -1; aspect-ratio: 4/3; }
}

/* Computer: il ritmo di Gabriele su 6 colonne, a giro di 12. */
@media (min-width: 901px) {
  .gallery-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .gallery-tile { grid-column: span 3; align-self: start; }
  /* 1-3: grande + due impilate (le due riempiono l'altezza della grande) */
  .gallery-tile:nth-child(12n+1) { grid-column: span 4; grid-row: span 2; aspect-ratio: 4/5; }
  .gallery-tile:nth-child(12n+2),
  .gallery-tile:nth-child(12n+3) { grid-column: span 2; aspect-ratio: auto; align-self: stretch; }
  /* 4 e 12: tutta larghezza */
  .gallery-tile:nth-child(12n+4),
  .gallery-tile:nth-child(12n+12) { grid-column: 1 / -1; aspect-ratio: 21/9; }
  /* 5-6: dittico sfalsato */
  .gallery-tile:nth-child(12n+6) { margin-top: clamp(3rem, 8vw, 6rem); }
  /* 7-9: tre */
  .gallery-tile:nth-child(12n+7),
  .gallery-tile:nth-child(12n+8),
  .gallery-tile:nth-child(12n+9) { grid-column: span 2; aspect-ratio: 3/4; }
  /* 10-11: alta + larga */
  .gallery-tile:nth-child(12n+10) { grid-column: span 2; aspect-ratio: 3/4; }
  .gallery-tile:nth-child(12n+11) { grid-column: span 4; aspect-ratio: 4/3; }
  /* gruppi incompleti in coda */
  .gallery-tile:nth-child(12n+1):last-child,
  .gallery-tile:nth-child(12n+5):last-child,
  .gallery-tile:nth-child(12n+7):last-child,
  .gallery-tile:nth-child(12n+10):last-child { grid-column: 1 / -1; grid-row: auto; aspect-ratio: 21/9; margin-top: 0; }
  .gallery-tile:nth-child(12n+1):nth-last-child(2),
  .gallery-tile:nth-child(12n+2):last-child { grid-column: span 3; grid-row: auto; aspect-ratio: 4/5; align-self: start; }
  .gallery-tile:nth-child(12n+7):nth-last-child(2),
  .gallery-tile:nth-child(12n+8):last-child { grid-column: span 3; aspect-ratio: 4/3; }
}

/* ============ LIGHTBOX ============ */
.gallery-tile { cursor: zoom-in; }

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(10, 10, 9, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s var(--ease-out);
  padding: clamp(2rem, 5vw, 4rem);
  backdrop-filter: blur(10px);
}
.lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}
.lightbox-figure {
  margin: 0;
  max-width: min(1400px, 92vw);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  transform: scale(0.96);
  transition: transform 0.45s var(--ease-out);
}
.lightbox.is-open .lightbox-figure { transform: scale(1); }
.lightbox-img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: clamp(8px, 1.2vw, 16px);
  display: block;
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.5);
}
.lightbox-caption {
  color: var(--bg);
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 14px;
  text-align: center;
  max-width: 600px;
}
.lightbox-caption:empty { display: none; }
.lightbox-caption .cap-num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.25rem;
  color: var(--accent-glow);
}
.lightbox-caption .cap-title {
  font-weight: 500;
  letter-spacing: 0.02em;
  color: rgba(239, 235, 226, 0.85);
}

.lightbox-btn {
  position: absolute;
  background: rgba(255, 255, 255, 0.14);
  border: 0;
  color: var(--bg);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.25s, border-color 0.25s;
  backdrop-filter: blur(8px);
}
.lightbox-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
}
.lightbox-btn svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
}
.lightbox-close {
  top: clamp(1.5rem, 3vw, 2.5rem);
  right: clamp(1.5rem, 3vw, 2.5rem);
}
.lightbox-prev,
.lightbox-next {
  top: 50%;
  transform: translateY(-50%);
}
.lightbox-prev { left: clamp(1rem, 3vw, 2.5rem); }
.lightbox-next { right: clamp(1rem, 3vw, 2.5rem); }

.lightbox-counter {
  position: absolute;
  top: clamp(1.5rem, 3vw, 2.5rem);
  left: clamp(1.5rem, 3vw, 2.5rem);
  color: rgba(239, 235, 226, 0.7);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.15em;
  font-variant-numeric: tabular-nums;
}

@media (max-width: 600px) {
  .lightbox-btn { width: 42px; height: 42px; }
  .lightbox-img { max-height: 68vh; }
  .lightbox-prev { left: 0.75rem; }
  .lightbox-next { right: 0.75rem; }
}

/* ============ FOOTER ============ */
footer {
  padding: clamp(3rem, 6vw, 5rem) var(--gutter) 2rem;
  background: var(--bg-dark);
  color: var(--bg);
  border-top: 1px solid rgba(255,255,255,0.1);
}
.footer-inner { max-width: var(--container); margin: 0 auto; }
.footer-top {
  display: flex;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 3rem;
  flex-wrap: wrap;
  gap: 2rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
.footer-brand {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 6rem);
  font-style: italic;
  font-weight: 400;
  line-height: 0.9;
  letter-spacing: -0.025em;
}
.footer-brand em { color: var(--accent-glow); }
.footer-tag {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.05em;
  opacity: 0.6;
  max-width: 22rem;
  line-height: 1.55;
  text-align: right;
}
.footer-cols {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-bottom: 3rem;
}
.footer-col-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0.55;
  margin-bottom: 1rem;
}
.footer-col p, .footer-col a, .footer-col li {
  font-size: 14px;
  opacity: 0.85;
  line-height: 1.7;
  list-style: none;
}
.footer-col a:hover { color: var(--accent-glow); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.12);
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 12px;
  opacity: 0.6;
}
.footer-bottom a { text-decoration: underline; text-underline-offset: 4px; }
.footer-bottom a:hover { color: var(--accent-glow); }
@media (max-width: 768px) {
  .footer-tag { text-align: left; }
  .footer-cols { grid-template-columns: 1fr 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* ============ PRIVACY PAGE ============ */
.privacy-content {
  max-width: 760px;
  margin: 0 auto;
}
.privacy-content h2 {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2.2vw, 1.7rem);
  font-weight: 400;
  margin-top: 3rem;
  margin-bottom: 1rem;
  letter-spacing: -0.015em;
  color: var(--accent);
}
.privacy-content p, .privacy-content li {
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink-2);
  margin-bottom: 1rem;
}
.privacy-content ul { padding-left: 1.5rem; margin-bottom: 1.5rem; }
.privacy-content a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.privacy-content strong { color: var(--ink); font-weight: 500; }

/* ============ MOTION RESPECT ============ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}


/* ============================================================
   WOW — motion layer (2026-09-07)
   Sipario d'ingresso e transizione tra pagine · lastra hero che si apre
   scorrendo · parole dei titoli che entrano in 3D · immagini con tendina
   e parallasse · cursore · bottoni magnetici · tilt sulle card · ticker
   ============================================================ */

/* --- sipario: copre la pagina finché è pronta, poi sale; scende dal basso quando si cambia pagina.
   Copre solo con html.js (lo script in testa). app.js lo alza (html.ready) al load e comunque
   entro 2,6 s; se app.js non arriva mai, l'animazione di sicurezza lo alza da sola dopo 2,8 s:
   il sipario non blocca mai la pagina. Sul blog non c'è (lo shell prende solo nav e footer). --- */
.curtain {
  position: fixed; inset: 0; z-index: 10000; background: var(--accent-fill); color: var(--on-accent);
  display: grid; place-items: center; pointer-events: none;
  transform: translateY(-101%); transition: transform 0.9s var(--ease);
}
html.js:not(.ready) .curtain { transform: translateY(0); animation: curtain-safety 0.9s var(--ease) 2.8s forwards; }
@keyframes curtain-safety { to { transform: translateY(-101%); visibility: hidden; } }
html.leaving .curtain { transform: translateY(0); transition-duration: 0.7s; pointer-events: auto; }
.curtain.from-bottom { transition: none; transform: translateY(101%); }
.curtain span {
  font-family: var(--font-display); font-style: italic; font-weight: 300; font-size: clamp(2.2rem, 6vw, 5rem); letter-spacing: -0.02em;
  opacity: 0; transform: translateY(14px); transition: opacity 0.6s var(--ease-out) 0.1s, transform 0.6s var(--ease-out) 0.1s;
  max-width: 90vw; text-align: center; line-height: 1.05;
}
html.js:not(.ready) .curtain span, html.leaving .curtain span { opacity: 1; transform: none; }
.curtain::after {
  content: ""; position: absolute; left: 50%; bottom: 18%; width: 0; height: 1px; background: rgba(239,235,226,0.6); transform: translateX(-50%);
  transition: width 1.2s var(--ease-out) 0.2s;
}
html.js:not(.ready) .curtain::after { width: min(320px, 50vw); }
/* la hero aspetta che il sipario sia salito (solo se app.js è partito: è lui che lo alza) */
html.fx:not(.ready) .hero .word, html.fx:not(.ready) .page-header .word { animation-play-state: paused; }
html.fx:not(.ready) .hero-sub, html.fx:not(.ready) .hero-actions { animation-play-state: paused; }

/* --- cursore (solo mouse): un punto che cresce sui link e sulle immagini.
   L'etichetta ("apri") la mette app.js nella lingua della pagina (data-hint). --- */
.cur {
  position: fixed; left: 0; top: 0; z-index: 10001; width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent-fill); pointer-events: none; opacity: 0; mix-blend-mode: multiply;
  transform: translate(-50%, -50%); transition: width 0.35s var(--ease-out), height 0.35s var(--ease-out), opacity 0.3s, background 0.3s;
}
.cur.on { opacity: 0.9; }
.cur.big { width: 64px; height: 64px; background: rgba(var(--accent-rgb), 0.16); }
.cur.pic { width: 84px; height: 84px; background: rgba(239, 235, 226, 0.55); mix-blend-mode: normal; }
.cur.pic::after { content: attr(data-hint); position: absolute; inset: 0; display: grid; place-items: center; font: 500 11px/1 var(--font-sans); letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink); }

/* --- lastra hero: parte come una finestra ad arco centrata e si apre a tutto schermo scorrendo.
   La scena esiste solo con app.js (.is-live): senza, è la foto intera con la didascalia. --- */
.hero-plate { position: relative; padding: 0; }
.hero-plate-sticky { position: relative; height: 72vh; min-height: 420px; overflow: hidden; }
.hero-plate.is-live { height: 160vh; margin-top: -8vh; }
.hero-plate.is-live .hero-plate-sticky { position: sticky; top: 0; height: 100vh; min-height: 0; }
.hero-plate-fig { position: absolute; inset: 0; margin: 0; }
.hero-plate.is-live .hero-plate-fig {
  /* la foto appare dentro una finestra ad arco che cresce fino a coprire tutto lo schermo (--mw la calcola app.js da --hp) */
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 130'><path d='M0 50A50 50 0 0 1 100 50V130H0Z' fill='%23000'/></svg>") 50% 46% / var(--mw, 320px) no-repeat;
  mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 130'><path d='M0 50A50 50 0 0 1 100 50V130H0Z' fill='%23000'/></svg>") 50% 46% / var(--mw, 320px) no-repeat;
  will-change: mask-size;
}
.hero-plate-fig img { width: 100%; height: 100%; object-fit: cover; transform: scale(calc(1.28 - var(--hp, 1) * 0.28)); will-change: transform; }
.hero-plate-fig figcaption {
  position: absolute; z-index: 2; left: var(--gutter); right: var(--gutter); bottom: clamp(1.5rem, 4vw, 3rem);
  display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; color: var(--bg);
  opacity: calc((var(--hp, 1) - 0.7) / 0.3); transform: translateY(calc(20px - var(--hp, 1) * 20px));
}
.hero-plate-fig figcaption b { font-family: var(--font-display); font-weight: 300; font-style: italic; font-size: clamp(1.6rem, 4vw, 3.4rem); letter-spacing: -0.02em; line-height: 1; max-width: 16ch; text-shadow: 0 10px 40px rgba(0,0,0,0.35); }
.hero-plate-fig figcaption small { font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase; opacity: 0.85; max-width: 26rem; text-align: right; line-height: 1.5; }
.hero-plate-fig::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, transparent 34%, rgba(10,10,9, calc(0.3 * var(--hp, 1))) 60%, rgba(10,10,9, calc(0.82 * var(--hp, 1)))); }
.hero-plate-hint {
  position: absolute; left: 50%; top: 3.5vh; transform: translateX(-50%); z-index: 2;
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted);
  opacity: calc(1 - var(--hp, 1) * 2.5); display: inline-flex; align-items: center; gap: 10px;
}
.hero-plate-hint::before { content: attr(data-hint); }
.hero-plate-hint::after { content: ""; width: 1px; height: 34px; background: var(--line-strong); animation: hint-drop 1.8s var(--ease) infinite; transform-origin: top; }
@keyframes hint-drop { 0% { transform: scaleY(0); transform-origin: top; } 45% { transform: scaleY(1); transform-origin: top; } 55% { transform: scaleY(1); transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }
.hero { min-height: 78vh; padding-bottom: 2rem; }

/* --- titoli: le parole entrano ruotando da sotto (maschera + rotazione 3D) --- */
.sw .w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 0.08em 0.14em; margin: 0 -0.08em -0.14em; perspective: 600px; }
.sw .w i { display: inline-block; font-style: inherit; transform-origin: 50% 100%; transform: translateY(105%) rotateX(-65deg); opacity: 0; transition: transform 1s var(--ease-out), opacity 0.5s; transition-delay: calc(var(--i, 0) * 45ms); will-change: transform; }
.sw.in .w i { transform: none; opacity: 1; will-change: auto; }
/* il blocco .reveal che contiene un titolo splittato anima solo gli altri figli: mai due animazioni sullo stesso testo */
.reveal:not(.stagger):has(> .sw) { opacity: 1; transform: none; }
.reveal:not(.stagger):has(> .sw) > :not(.sw) { opacity: 0; transform: translateY(26px); transition: opacity 1s var(--ease-out), transform 1s var(--ease-out); }
.reveal.in:not(.stagger):has(> .sw) > :not(.sw) { opacity: 1; transform: none; }
.reveal.in:not(.stagger):has(> .sw) > :not(.sw):nth-child(2) { transition-delay: 0.15s; }
.reveal.in:not(.stagger):has(> .sw) > :not(.sw):nth-child(3) { transition-delay: 0.3s; }
.reveal.in:not(.stagger):has(> .sw) > :not(.sw):nth-child(4) { transition-delay: 0.45s; }
.reveal.stagger > .sw { opacity: 1 !important; transform: none !important; transition: none !important; }

/* --- immagini: si aprono a tendina dal basso e scorrono in parallasse (classi messe da app.js) --- */
/* la tendina sta sull'immagine interna: il contenitore resta misurabile dall'IntersectionObserver */
.wipe > img, .wipe > iframe { clip-path: inset(100% 0 0 0 round 18px); transition: clip-path 1.3s var(--ease), transform 1.2s var(--ease-out), filter 1.4s var(--ease-out); }
.wipe.in > img, .wipe.in > iframe { clip-path: inset(0 0 0 0 round 18px); }
.wipe.done > img, .wipe.done > iframe { clip-path: none; }
.px img { translate: 0 var(--py, 0px); scale: 1.14; }
.hero-feature-tile.px .hero-feature-img { scale: 1.08; }

/* --- card che si inclinano seguendo il cursore --- */
.tilt { transform-style: preserve-3d; }
.tilt > * { transform: translateZ(0); }

/* --- velocità di scroll: la galleria si inclina appena mentre scorri veloce --- */
.gallery-sections { will-change: transform; transform-origin: 50% 50%; }

/* --- nav: le voci si sottolineano scorrendo da sinistra, il marchio respira --- */
.nav-brand { transition: letter-spacing 0.6s var(--ease-out); }
.nav-brand:hover { letter-spacing: 0.02em; }

/* --- footer: colonne che entrano a scaglioni (solo con app.js: html.fx) --- */
html.fx .footer-cols > * { opacity: 0; transform: translateY(18px); transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out); }
html.fx .footer-cols.in > * { opacity: 1; transform: none; }
.footer-cols.in > :nth-child(2) { transition-delay: 0.1s; } .footer-cols.in > :nth-child(3) { transition-delay: 0.2s; } .footer-cols.in > :nth-child(4) { transition-delay: 0.3s; } .footer-cols.in > :nth-child(5) { transition-delay: 0.4s; }

@media (hover: none), (pointer: coarse) { .cur { display: none; } }
@media (max-width: 760px) {
  .hero-plate.is-live { height: 130vh; }
  .hero-plate-fig figcaption { flex-direction: column; align-items: flex-start; }
  .hero-plate-fig figcaption small { text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  .curtain { display: none; }
  .sw .w i { transform: none; opacity: 1; }
  .wipe > img, .wipe > iframe { clip-path: none; }
}


/* ============================================================
   WOW 2 — le sezioni esistenti portate al massimo (2026-09-07)
   ============================================================ */

/* --- sipario a tre pannelli: il centro sale per primo, i lati lo seguono --- */
.curtain::before, .curtain::after {
  content: ""; position: absolute; top: 0; bottom: 0; width: 33.5%; pointer-events: none;
  transition: transform 0.9s var(--ease);
}
.curtain::before { left: 0; background: var(--accent-fill-2); transition-delay: 0.08s; }
.curtain::after { right: 0; background: var(--curtain-3); transition-delay: 0.16s; }
html.ready:not(.leaving) .curtain::before, html.ready:not(.leaving) .curtain::after { transform: translateY(-101%); }
html.js:not(.ready) .curtain::before, html.js:not(.ready) .curtain::after, html.leaving .curtain::before, html.leaving .curtain::after { transform: translateY(0); }
.curtain.from-bottom::before, .curtain.from-bottom::after { transition: none; transform: translateY(101%); }
.curtain span { position: relative; z-index: 2; }

/* --- nav: le lettere delle voci ruotano al passaggio --- */
.ls { display: inline-flex; white-space: pre; }
.ls i { display: inline-block; font-style: inherit; transform-origin: 50% 50%; transition: transform 0.55s cubic-bezier(0.2, 0.8, 0.2, 1); backface-visibility: hidden; }
.nav-links a:hover .ls i { transform: rotateX(360deg); }

/* --- hero e testate interne: si ritirano e sfumano mentre scorri --- */
.hero, .page-header { transform: translateY(calc(var(--hs, 0) * -70px)) scale(calc(1 - var(--hs, 0) * 0.06)); opacity: calc(1 - var(--hs, 0) * 1.15); transform-origin: 50% 85%; will-change: transform, opacity; }
@keyframes rise-in { 0% { transform: translateY(110%) rotate(3deg); opacity: 0; filter: blur(6px); } 100% { transform: translateY(0) rotate(0); opacity: 1; filter: blur(0); } }
.hero-title .word, .page-header h1 .word { transform-origin: 0 100%; }
.hero-eyebrow, .page-header .eyebrow { position: relative; }

/* --- lastra hero: le parole della didascalia salgono quando la lastra è quasi aperta --- */
.hero-plate-fig figcaption b .w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 0.06em 0.12em; margin: 0 -0.06em -0.12em; }
.hero-plate-fig figcaption b .w i { display: inline-block; font-style: inherit; transform: translateY(110%); transition: transform 0.9s var(--ease-out); transition-delay: calc(var(--i, 0) * 50ms); }
.hero-plate-fig.open figcaption b .w i { transform: none; }
.hero-plate.is-live .hero-plate-fig figcaption small { opacity: 0; transform: translateY(8px); transition: opacity 0.8s var(--ease-out) 0.4s, transform 0.8s var(--ease-out) 0.4s; }
.hero-plate.is-live .hero-plate-fig.open figcaption small { opacity: 0.85; transform: none; }
/* il nome in filigrana che attraversa la lastra aperta: lo crea app.js dal nome vero */
.hero-plate-ghost {
  position: absolute; left: 0; bottom: 26%; z-index: 1; white-space: nowrap; pointer-events: none;
  font-family: var(--font-display); font-style: italic; font-weight: 300; font-size: clamp(6rem, 22vw, 20rem); line-height: 1; letter-spacing: -0.03em;
  color: transparent; -webkit-text-stroke: 1px rgba(239,235,226,0.34);
  opacity: calc((var(--hp, 1) - 0.6) / 0.4); transform: translateX(calc(30vw - var(--hp, 1) * 60vw));
}

/* --- mission card: mentre si espande affiora una fotografia sotto il verde --- */
.mission-card { overflow: hidden; isolation: isolate; }
.mission-card::before {
  content: ""; position: absolute; inset: -6%; z-index: -1; pointer-events: none;
  background: var(--mimg) center / cover no-repeat;
  opacity: calc(var(--p, 0) * 0.34); filter: saturate(0.6) contrast(1.05);
  transform: translateY(calc((1 - var(--p, 0)) * 4%)) scale(calc(1.06 - var(--p, 0) * 0.06));
}
.mission-card::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(80% 70% at 50% 40%, transparent 30%, rgba(10,10,9, calc(var(--p, 0) * 0.35)));
}
.mission-card--inverted::before { opacity: calc((1 - var(--p, 0)) * 0.3); }

/* --- vantaggi: entrano come carte servite in 3D, l'immagine si apre a cerchio, il numero in filigrana --- */
.advantages-grid { perspective: 1400px; counter-reset: adv; }
.advantages-grid.reveal.stagger > * { transform: translateY(70px) rotateX(14deg); transform-origin: 50% 100%; }
.advantages-grid.reveal.in.stagger > * { transform: none; }
.advantage { position: relative; counter-increment: adv; }
.advantage::before {
  content: "0" counter(adv); position: absolute; right: 0.4rem; top: -1.2rem; z-index: 2; pointer-events: none;
  font-family: var(--font-display); font-style: italic; font-weight: 300; font-size: clamp(4rem, 7vw, 7rem); line-height: 1; color: var(--accent); opacity: 0.14;
  transform: translateY(20px); transition: transform 0.9s var(--ease-out) 0.3s, opacity 0.9s var(--ease-out) 0.3s;
}
.advantages-grid.in .advantage::before { transform: none; }
.advantage:hover::before { opacity: 0.32; }
.advantage-media.wipe > img { clip-path: circle(0% at 50% 62%); transition: clip-path 1.4s var(--ease), transform 1.4s var(--ease-out), filter 0.8s; }
.advantage-media.wipe.in > img { clip-path: circle(80% at 50% 62%); }
.advantage-media img { filter: saturate(0.82); transition: transform 1.4s var(--ease-out), filter 0.8s; }
.advantage:hover .advantage-media img { filter: saturate(1.05); }

/* --- feature 01/02: l'immagine si apre dal centro, il numero rotola, gli em si sottolineano a mano --- */
.feature-media.wipe > img { clip-path: inset(0 50% 0 50% round 24px); transition: clip-path 1.5s var(--ease), transform 1.4s var(--ease-out); }
.feature-media.wipe.in > img { clip-path: inset(0 0 0 0 round 24px); }
.feature-num { display: inline-block; overflow: hidden; }
.feature-num .w { display: inline-block; overflow: hidden; vertical-align: top; }
.feature-num .w i { display: inline-block; font-style: inherit; transform: translateY(110%); transition: transform 0.9s var(--ease-out); transition-delay: calc(var(--i, 0) * 80ms); }
.feature-text.in .feature-num .w i { transform: none; }
.feature-rule { transform-origin: left; transition: transform 1.1s var(--ease-out) 0.35s; }
html.fx .feature-rule { transform: scaleX(0); }
html.fx .feature-text.in .feature-rule { transform: scaleX(1); }
.sw em i { position: relative; }
.sw em i::after {
  content: ""; position: absolute; left: 0.02em; right: 0.02em; bottom: 0.04em; height: 0.055em; border-radius: 2px;
  background: currentColor; opacity: 0.38; transform: scaleX(0); transform-origin: left;
  transition: transform 0.8s var(--ease-out); transition-delay: calc(0.55s + var(--i, 0) * 60ms);
}
.sw.in em i::after { transform: scaleX(1); }

/* --- servizi: la riga sotto il cursore va a fuoco, le altre si abbassano; il numero cresce --- */
.services-list:hover .service-item:not(:hover) { opacity: 0.42; }
.service-item { transition: opacity 0.5s var(--ease-out); }
.service-num { transition: transform 0.6s var(--ease-out), color 0.4s; transform-origin: left top; }
.service-item:hover .service-num { transform: scale(1.35); }
.service-media.wipe > img { clip-path: inset(0 0 0 100% round 20px); }
.service-media.wipe.in > img { clip-path: inset(0 0 0 0 round 20px); }
.service-media { transition: transform 0.6s var(--ease-out); }

/* --- pilastri (chi siamo): immagini a cerchio, numeri che salgono --- */
.pillar-media.wipe > img { clip-path: circle(0% at 50% 50%); transition: clip-path 1.3s var(--ease), transform 1.4s var(--ease-out); }
.pillar-media.wipe.in > img { clip-path: circle(75% at 50% 50%); }

/* --- galleria: foto quasi in bianco e nero che prendono colore in vista, lightbox che vola dalla miniatura --- */
.gallery-tile img { transition: transform 1.2s var(--ease-out), filter 1.4s var(--ease-out); }
html.fx .gallery-tile img { filter: saturate(0.35); }
html.fx .gallery-tile.in img { filter: saturate(1); }
html.fx .gallery-tile.in:hover img { filter: saturate(1.1); }
.flip-ghost { position: fixed; z-index: 9998; object-fit: cover; border-radius: 16px; pointer-events: none; transition: all 0.75s var(--ease); box-shadow: 0 40px 90px rgba(10,10,9,0.35); }
.lightbox { transition-delay: 0.05s; }

/* --- contatti: le righe si tracciano, la mappa si apre a cerchio, i campi si accendono --- */
/* le voci (testo e riga) si scoprono da sinistra, una dopo l'altra */
.contact-item { transition: clip-path 1.2s var(--ease); }
html.fx .contact-item { clip-path: inset(0 100% 0 0); }
html.fx .contact-list.in .contact-item { clip-path: inset(0 0 0 0); }
.contact-list.in .contact-item:nth-child(2) { transition-delay: 0.12s; } .contact-list.in .contact-item:nth-child(3) { transition-delay: 0.24s; } .contact-list.in .contact-item:nth-child(4) { transition-delay: 0.36s; }
.contact-map.wipe > iframe { clip-path: circle(14% at 50% 50%); transition: clip-path 1.6s var(--ease); }
.contact-map.wipe.in > iframe { clip-path: circle(80% at 50% 50%); }
.form-field { position: relative; }
.form-field::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform 0.5s var(--ease-out); border-radius: 2px; pointer-events: none; }
.form-field:focus-within::after { transform: scaleX(1); }
.form-field label { transition: color 0.3s; }
.form-field:focus-within label { color: var(--accent); }

/* --- bottoni: una luce morbida segue il cursore dentro il bottone --- */
.btn-primary, .btn-outline { position: relative; overflow: hidden; isolation: isolate; }
.btn-primary::after, .btn-outline::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 0.35s; background: radial-gradient(140px circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,0.18), transparent 70%); }
.btn-outline::after { background: radial-gradient(120px circle at var(--mx, 50%) var(--my, 50%), rgba(var(--accent-rgb), 0.10), transparent 70%); }
.btn-primary:hover::after, .btn-outline:hover::after { opacity: 1; }

/* --- footer: il marchio sale lettera per lettera, i link scivolano con una freccia --- */
.footer-brand .w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 0.06em 0.14em; margin: 0 -0.06em -0.14em; }
.footer-brand .w i { display: inline-block; font-style: inherit; transform: translateY(110%); transition: transform 1s var(--ease-out); transition-delay: calc(var(--i, 0) * 90ms); }
.footer-top.in .footer-brand .w i { transform: none; }
.footer-col a { position: relative; display: inline-block; transition: transform 0.4s var(--ease-out), opacity 0.3s; }
.footer-col a::before { content: "→"; position: absolute; left: -1.2em; top: 0; opacity: 0; transform: translateX(-6px); transition: opacity 0.3s, transform 0.4s var(--ease-out); color: var(--accent-glow); }
.footer-col a:hover { transform: translateX(1.2em); }
.footer-col a:hover::before { opacity: 1; transform: none; }

/* --- lo sfondo vira leggermente quando una sezione densa è al centro --- */
body { transition: background 1.2s var(--ease); }
html.tint body { background: var(--bg-2); }
html.tint .nav.scrolled { background: rgba(229, 223, 210, 0.92); }

@media (max-width: 760px) {
  .hero-plate-ghost { font-size: 5rem; bottom: 12%; }
  .advantage::before { font-size: 3.5rem; top: -0.8rem; }
  .services-list:hover .service-item:not(:hover) { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .hero, .page-header { transform: none; opacity: 1; }
  .wipe > img, .wipe > iframe { clip-path: none !important; }
  .gallery-tile img { filter: none; }
  .footer-brand .w i, .hero-plate-fig figcaption b .w i, .feature-num .w i { transform: none; }
  html.fx .feature-rule { transform: none; } html.fx .contact-item { clip-path: none; }
}


/* --- servizi (desktop): la lista diventa un coverflow 3D che scorre con la pagina; il servizio a fuoco mostra il testo.
   Solo con app.js (.is-flow). La corsa cresce col numero delle voci (--n, messo da app.js):
   100vh + 64vh a voce = i 420vh dell'originale con 5 servizi. --- */
@media (min-width: 1000px) {
  .services-stage.is-flow { min-height: calc(100vh + var(--n, 5) * 64vh); padding-top: 0; padding-bottom: 0; position: relative; }
  .is-flow .services-list {
    position: sticky; top: 0; height: 100vh; max-width: none; margin: 0; display: block; overflow: hidden;
    perspective: 1500px; perspective-origin: 50% 45%; isolation: isolate;
  }
  .is-flow .services-list::after {
    content: ""; position: absolute; left: var(--gutter); right: var(--gutter); bottom: 2.2rem; height: 1px; background: var(--line-strong); z-index: 3;
    -webkit-mask: linear-gradient(90deg, #000 calc(var(--sp, 0) * 100%), rgba(0,0,0,0.18) calc(var(--sp, 0) * 100%)); mask: linear-gradient(90deg, #000 calc(var(--sp, 0) * 100%), rgba(0,0,0,0.18) calc(var(--sp, 0) * 100%));
  }
  .is-flow .services-list.reveal > .service-item, .is-flow .service-item {
    position: absolute; left: 50%; top: 50%; z-index: var(--z, 1);
    width: min(500px, 38vw); height: min(calc(min(500px, 38vw) * 1.25), 76vh);
    display: block; padding: 0; border: 0; border-radius: 24px; overflow: hidden; background: var(--bg-dark); color: var(--bg);
    transform: translate(-50%, -50%) translateX(var(--tx, 0px)) scale(var(--sc, 1)) rotateY(var(--ry, 0deg)) !important;
    opacity: var(--op, 1) !important; transform-origin: 50% 50%; will-change: transform, opacity;
    box-shadow: 0 30px 80px rgba(10,10,9, calc(0.18 + 0.3 * var(--f, 0))); transition: none;
  }
  .is-flow .services-list:hover .service-item:not(:hover) { opacity: var(--op, 1) !important; }
  .is-flow .service-item .service-media { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; transform: none !important; }
  .is-flow .service-item .service-media > img { clip-path: none !important; }
  .is-flow .service-item .service-media img { width: 100%; height: 100%; object-fit: cover; filter: brightness(calc(0.5 + 0.28 * var(--f, 0))) saturate(calc(0.6 + 0.35 * var(--f, 0))); transform: none !important; scale: 1.06; }
  .is-flow .service-item .service-num { position: absolute; left: 1.6rem; top: 1.4rem; z-index: 3; color: var(--bg); padding: 0; font-size: clamp(1.6rem, 2.4vw, 2.2rem); transform: none !important; text-shadow: 0 2px 14px rgba(0,0,0,0.5); }
  .is-flow .service-item .service-content {
    position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; padding: 4rem 1.8rem 1.8rem; gap: 0.7rem;
    background: linear-gradient(180deg, transparent, rgba(10,10,9,0.5) 26%, rgba(10,10,9,0.88) 56%, rgba(10,10,9,0.96));
    opacity: var(--f, 0); transform: translateY(calc((1 - var(--f, 0)) * 18px));
  }
  .is-flow .service-item .service-content .eyebrow { color: rgba(239,235,226,0.7); }
  .is-flow .service-item .service-content h3 { color: var(--bg); font-size: clamp(1.6rem, 2.4vw, 2.2rem); }
  .is-flow .service-item .service-content h3 em { color: var(--accent-glow); }
  .is-flow .service-item .service-content p { color: rgba(239,235,226,0.82); font-size: 0.95rem; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
  .is-flow .service-item .service-cta { color: var(--bg); }
  .services-intro-section { position: relative; z-index: 2; }
}


/* --- mission card a tutto schermo (servizi, galleria): niente scatto, si apre con lo scroll e l'interno si anima --- */
.mission-section--full.is-live { min-height: 240vh; }
.mission-card--full { transition: none; --p: var(--pp, 0) !important; }
.mission-card--full::before {
  opacity: calc(var(--p) * 0.46);
  transform: scale(calc(1.32 - var(--p) * 0.24)) translateY(calc((1 - var(--p)) * 6%));
  /* le foto chiare slavavano il fondo accento e il testo crema spariva */
  filter: saturate(0.62) contrast(1.02) brightness(0.5);
}
.mission-card--full.lit::before { animation: mission-kb 16s ease-in-out infinite alternate; }
@keyframes mission-kb { from { transform: scale(1.08) translate(0, 0); } to { transform: scale(1.18) translate(-2%, -3%); } }
.mission-card--full .mission-card-inner { position: relative; }
.is-live .mission-card--full .mission-card-inner { transform: scale(calc(0.84 + var(--p) * 0.16)); }
/* il nome in filigrana dietro la card aperta: lo crea app.js dal nome vero */
.mc-ghost {
  position: absolute; left: 50%; top: 50%; z-index: -1; white-space: nowrap; pointer-events: none;
  font-family: var(--font-display); font-style: italic; font-weight: 300; font-size: clamp(6rem, 20vw, 18rem); line-height: 1; letter-spacing: -0.03em;
  color: transparent; -webkit-text-stroke: 1px rgba(239, 235, 226, 0.32);
  transform: translate(calc(-50% + (0.5 - var(--p)) * 70vw), -50%); opacity: calc((var(--p) - 0.45) * 1.6);
}
/* l'interno aspetta che la card sia quasi aperta, poi entra a scaglioni: riga, parole del titolo, testo, bottone */
.mission-card--full .reveal.stagger > * { opacity: 0 !important; transform: translateY(26px) !important; transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out) !important; }
.mission-card--full .reveal.stagger > h2 { opacity: 1 !important; transform: none !important; }
.mission-card--full.lit .reveal.stagger > * { opacity: 1 !important; transform: none !important; }
.mission-card--full.lit .reveal.stagger > .eyebrow { transition-delay: 0.05s !important; }
.mission-card--full.lit .reveal.stagger > p { transition-delay: 0.55s !important; }
.mission-card--full.lit .reveal.stagger > .mission-btn { transition-delay: 0.75s !important; }
.mission-card--full h2 .w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 0.06em 0.14em; margin: 0 -0.06em -0.14em; }
.mission-card--full h2 .w i { display: inline-block; font-style: inherit; transform: translateY(110%) rotate(3deg); transform-origin: 0 100%; transition: transform 1s var(--ease-out); transition-delay: calc(0.15s + var(--i, 0) * 70ms); }
.mission-card--full.lit h2 .w i { transform: none; }
.mission-card--full .eyebrow::before { transform-origin: left; transition: transform 0.9s var(--ease-out) 0.1s; }
@media (prefers-reduced-motion: reduce) {
  .mission-section--full { min-height: 0; }
  .mission-card--full { --p: 1 !important; }
  .mission-card--full .reveal.stagger > *, .mission-card--full h2 .w i { opacity: 1 !important; transform: none !important; }
  .mission-card--full::before, .mission-card--full.lit::before { animation: none; }
}


/* ============================================================
   WOW 3 — sfondo sempre bianco ma dinamico, accento rosso (2026-09-07)
   ============================================================ */
:root {
  --bg: #ffffff;
  --bg-2: #ffffff;
  --surface: #f5f4f1;
  --ink: #0b0b0b;
  --ink-2: #2b2b2b;
  --muted: #6d6d6d;
  --line: rgba(11, 11, 11, 0.12);
  --line-strong: rgba(11, 11, 11, 0.3);
  /* rosso, varianti e bagliore: blocco PALETTE in fondo al foglio */
}
html { background: #fff; }
body { background: #fff; --bgx: 0px; --bgy: 0px; --sw: -20%; }
/* trama di punti che scorre in parallasse con lo scroll e segue il mouse, più una riga rossa sottile in diagonale che attraversa la pagina scorrendo */
body::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(112deg, transparent calc(var(--sw) - 0.5px), rgba(var(--accent-rgb), 0.55) var(--sw), transparent calc(var(--sw) + 0.5px)),
    radial-gradient(circle, rgba(11, 11, 11, 0.13) 1px, transparent 1.4px);
  background-size: 100% 100%, 30px 30px;
  background-position: 0 0, var(--bgx) var(--bgy);
}
body::before { opacity: 0.028; }
html.tint body { background: #fafaf8; }
.nav.scrolled, .nav.solid { background: rgba(255, 255, 255, 0.9); }
html.tint .nav.scrolled { background: rgba(250, 250, 248, 0.92); }
/* le sezioni lasciano vedere la trama: bianco trasparente, non coprente */
section, .mission-section, .contact-form-section, .contact-map-section, .services-intro-section, .gallery-sections { background: transparent !important; }
section[style*="--bg-2"] { background: transparent !important; }
/* superfici: le card si staccano dal bianco con un grigio caldo leggerissimo, non con un colore */
.mission-card { background: color-mix(in srgb, var(--surface), var(--accent-deep) calc(var(--p) * 100%)); }
.mission-card h2 em { color: color-mix(in srgb, var(--accent), var(--accent-glow) calc(var(--p) * 100%)); }
.mission-card--inverted { background: color-mix(in srgb, var(--accent-deep), var(--surface) calc(var(--p) * 100%)); }
.mission-btn { background: color-mix(in srgb, var(--ink), #fff calc(var(--p) * 100%)); color: color-mix(in srgb, #fff, var(--ink) calc(var(--p) * 100%)); }
.mission-btn:hover { background: var(--cta-btn-hover); color: var(--on-cta-hover); }
.mc-ghost { -webkit-text-stroke: 1px rgba(255, 255, 255, 0.3); }
.hero-feature-card, .services-intro-card, .form-field input, .form-field textarea { background: var(--surface); }
.feature-media, .gallery-tile, .advantage-media, .pillar-media, .service-media { background: var(--surface); }
.curtain { background: var(--accent-fill); }
.curtain::before { background: var(--accent-fill-2); }
.curtain::after { background: var(--curtain-3); }
.curtain span { color: var(--on-accent); }
.cur { background: var(--accent-fill); }
.cur.big { background: rgba(var(--accent-rgb), 0.16); }
.cur.pic { background: rgba(255, 255, 255, 0.72); }
::selection { background: var(--accent-fill); color: var(--on-accent); }
.hero-plate-ghost { -webkit-text-stroke: 1px rgba(255, 255, 255, 0.6); }
.hero-plate-hint::after { background: var(--accent); }
.advantage::before { color: var(--accent); }
.btn-outline::after { background: radial-gradient(120px circle at var(--mx, 50%) var(--my, 50%), rgba(var(--accent-rgb), 0.12), transparent 70%); }
.footer-col a::before { color: var(--accent); }
/* footer: bianco come tutto il resto, testo scuro, accenti rossi */
footer { background: #fff; color: var(--ink); border-top: 1px solid var(--line); }
.footer-top { border-bottom-color: var(--line); }
.footer-brand em { color: var(--accent); }
.footer-tag, .footer-col-label { opacity: 0.6; }
.footer-col p, .footer-col a, .footer-col li { color: var(--ink-2); }
.footer-bottom { color: var(--muted); border-top-color: var(--line); }
.footer-bottom a { color: var(--ink); }
@media (prefers-reduced-motion: reduce) { body::after { background-position: 0 0, 0 0; } }


/* --- hero feature (servizi): la card di vetro non è più tagliata in altezza; il riquadro cresce con il suo contenuto --- */
@media (min-width: 901px) {
  .hero-feature-tile { display: grid; align-items: center; justify-items: start; min-height: clamp(540px, 78vh, 780px); }
  .hero-feature-card {
    position: relative; top: auto; bottom: auto; left: auto; inset: auto;
    margin: clamp(1.5rem, 3vw, 2.5rem); width: clamp(340px, 44%, 600px); max-width: calc(100% - 2 * clamp(1.5rem, 3vw, 2.5rem));
    min-height: 0; overflow: visible;
  }
  .hero-feature-body { font-size: clamp(0.95rem, 1.05vw, 1.05rem); }
}


/* --- apertura servizi: niente riquadro né scritta in filigrana, solo il titolo centrato sul bianco --- */
.services-intro-card { background: transparent !important; box-shadow: none !important; border: 0 !important; padding-left: 0; padding-right: 0; }



/* ============================================================
   HERO FEATURE (servizi) — film in tre atti (2026-09-07)
   1. un numero gigante con la foto dentro le lettere · 2. il numero cresce fino a uscire dallo schermo e la foto emerge
   3. la foto si sposta a destra e da sinistra entra il pannello con titolo, testo e CTA. Tutto guidato dallo scroll (app.js).
   Nello stampo il numero è QUANTI servizi ci sono (lo conta app.js: data-num) e la riga sotto è
   l'etichetta "Servizi" (data-hint): l'originale diceva "−40%", una promessa che il cliente non fa.
   Solo con app.js e una foto (.film): senza, la card resta appoggiata sulla foto.
   ============================================================ */
@media (min-width: 901px) {
  section.hero-feature.film { min-height: 280vh; padding: 0 !important; position: relative; }
  .film .hero-feature-tile {
    position: sticky !important; top: 0; height: 100vh !important; min-height: 0 !important; max-width: none !important;
    display: block !important; overflow: hidden !important; border-radius: 0 !important; background: #fff !important; transform: none !important;
    -webkit-mask-image: none !important; mask-image: none !important; isolation: isolate;
  }
  .film .hero-feature-tile > .hero-feature-img {
    position: absolute !important; inset: clamp(1rem, 2vw, 2rem) !important; width: auto !important; height: auto !important; z-index: 1;
    border-radius: 28px; object-fit: cover; opacity: var(--io, 0);
    clip-path: inset(0 0 0 calc(var(--sp, 0) * 46%) round 28px) !important;
    scale: var(--ix, 1.1) !important; translate: 0 0 !important; transform-origin: 70% 50%; transition: none !important; filter: saturate(0.95) contrast(1.04);
  }
  .film .hero-feature-overlay {
    position: absolute !important; inset: 0 !important; z-index: 2; display: grid; place-items: center;
    background: none !important; pointer-events: none; opacity: var(--no, 1);
  }
  /* la foto vive dentro le cifre del numero */
  .film .hero-feature-overlay::before {
    content: attr(data-num); white-space: nowrap; padding: 0.05em 0.22em 0.08em 0.1em; /* il corsivo sporge: la scatola deve coprirlo, altrimenti la foto non si dipinge sulle sporgenze */
    font-family: var(--font-display); font-style: italic; font-weight: 300; font-size: clamp(10rem, 30vw, 30rem); line-height: 1; letter-spacing: -0.06em;
    background: var(--hfimg) 50% 40% / cover no-repeat; -webkit-background-clip: text; background-clip: text; color: transparent;
    transform: scale(var(--ns, 1)); transform-origin: 52% 50%; will-change: transform;
  }
  /* la riga sotto il numero */
  .film .hero-feature-overlay::after {
    content: attr(data-hint); position: absolute; left: 50%; bottom: clamp(2rem, 6vh, 4rem); transform: translateX(-50%);
    font-family: var(--font-sans); font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); white-space: nowrap;
    opacity: calc(1 - var(--ns, 1) + 1); padding-top: 1rem; border-top: 1px solid var(--line-strong); min-width: 12rem; text-align: center;
  }
  .film .hero-feature-card {
    position: absolute !important; z-index: 3; left: clamp(1rem, 2vw, 2rem); top: clamp(1rem, 2vw, 2rem); bottom: clamp(1rem, 2vw, 2rem);
    width: calc(46% - clamp(1rem, 2vw, 2rem)) !important; max-width: none !important; margin: 0 !important;
    padding: clamp(2rem, 4vw, 4rem) !important; background: #fff !important; border: 0 !important; box-shadow: none !important;
    -webkit-backdrop-filter: none !important; backdrop-filter: none !important; border-radius: 28px; overflow: hidden !important;
    display: flex; flex-direction: column; justify-content: center; gap: 1.5rem;
    opacity: var(--co, 0); transform: translateX(calc((1 - var(--co, 0)) * -48px));
  }
  .film .hero-feature-title { font-size: clamp(2.6rem, 4.6vw, 4.8rem) !important; line-height: 0.96 !important; letter-spacing: -0.03em; }
  .film .hero-feature-body { font-size: clamp(0.98rem, 1.1vw, 1.08rem) !important; line-height: 1.62; max-width: 30rem; }
  /* CTA: pillola pulita; in hover l'onda rossa parte dalla freccia e il testo diventa bianco */
  .film .hero-feature-cta { margin: 0.6rem 0 0 !important; padding: 1.1rem 1.7rem !important; border: 1px solid var(--line-strong) !important; border-radius: 999px; overflow: hidden; width: 100%; align-self: flex-start; }
  .film .hero-feature-cta:hover { color: var(--on-accent); border-color: var(--accent-fill) !important; }
  .film .hero-feature-cta-arrow { width: 40px; height: 40px; border-radius: 50%; background: var(--surface); transition: background 0.4s, transform 0.5s var(--ease-out); }
  .film .hero-feature-cta-arrow svg { width: 20px; height: 20px; }
  .film .hero-feature-cta:hover .hero-feature-cta-arrow { background: rgba(255, 255, 255, 0.18); transform: rotate(45deg); }
  /* il reveal generico della sezione non deve nascondere la scena */
  .hero-feature.film.reveal { opacity: 1 !important; transform: none !important; }
  .hero-feature.film.reveal .hero-feature-card > * { opacity: 1 !important; transform: none !important; }
}


/* ============================================================
   ===== MOBILE PASS (2026-09-08) =====
   Solo aggiunte in coda: correzioni per telefono (<= 900px).
   Il desktop non è toccato.
   ============================================================ */
@media (max-width: 900px) {

  /* --- protezione: la pagina non scorre mai in orizzontale.
         `clip` e non `hidden`, e su html e mai su body: su body ucciderebbe position:sticky --- */
  html { overflow-x: clip; }

  /* --- i riquadri che ritagliano foto ingrandite (parallasse, maschere, wipe) non devono
         diventare scroller orizzontali: `clip` toglie lo scorrimento interno lasciando il taglio --- */
  .hero-plate-sticky,
  .mission-card,
  .advantage-media,
  .advantage-cta,
  .feature-media,
  .about-showcase,
  .pillar-media,
  .hero-feature-tile,
  .service-media,
  .gallery-tile { overflow: clip; }

  /* --- "I nostri vantaggi unici": la filigrana gigante "Vantaggi" usciva a destra
         (unica causa dello scroll orizzontale di index) e copriva il paragrafo --- */
  .advantages-head-mark { display: none; }

  /* --- il numero 01/02/03 delle card resta dentro lo schermo --- */
  .advantage::before {
    right: 1.1rem;
    top: -0.4rem;
    font-size: 2.8rem;
    opacity: 0.18;
  }

  /* --- card dei vantaggi: su telefono la CTA non copre più metà della foto con un
         pannello sfocato; torna una pillola compatta appoggiata in basso a destra --- */
  .advantage:not(.is-expanded) .advantage-cta,
  .advantage.is-expanded .advantage-cta,
  .advantage:hover .advantage-cta {
    position: absolute;
    left: auto;
    right: 0.9rem;
    bottom: 0.9rem;
    width: auto;
    height: auto;
    min-height: 46px;
    padding: 0 1rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.55rem;
    background: rgba(255, 255, 255, 0.94);
    color: var(--ink);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    box-shadow: 0 6px 20px rgba(10, 10, 9, 0.20);
    transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out);
  }
  .advantage:not(.is-expanded) .advantage-cta-label,
  .advantage.is-expanded .advantage-cta-label,
  .advantage:hover .advantage-cta-label {
    max-width: none;
    opacity: 1;
    font-size: 1.1rem;
    line-height: 1;
    transition-delay: 0s;
  }
  .advantage:not(.is-expanded) .advantage-cta > svg:last-child,
  .advantage.is-expanded .advantage-cta > svg:last-child,
  .advantage:hover .advantage-cta > svg:last-child { width: 15px; height: 15px; }
  /* le righe decorative avevano senso solo dentro il pannello grande */
  .advantage .advantage-cta-decor { display: none; }
  /* la foto resta sempre visibile: niente sollevamento né zoom sulla card espansa */
  .advantage.is-expanded { transform: none; }
  .advantage.is-expanded .advantage-media img { transform: none; }
  /* velo un po' più marcato sotto la pillola */
  .advantage-media::after { background: linear-gradient(180deg, transparent 55%, rgba(10, 10, 9, 0.26)); }

  /* --- mission card: con line-height 1 le righe del titolo si toccavano;
         la foto sotto il colore era troppo forte e mangiava il contrasto del titolo --- */
  .mission-card h2 { line-height: 1.12; }
  .mission-card::before { opacity: calc(var(--p, 0) * 0.2); }
  .mission-card--inverted::before { opacity: calc((1 - var(--p, 0)) * 0.2); }
  .mission-card--full h2 .w { padding-bottom: 0.2em; margin-bottom: -0.2em; }

  /* --- mission card a tutto schermo: scena più corta, filigrana via (attraversava il testo)
         e velo pieno al posto del radiale, così il testo bianco non finisce su una foto chiara --- */
  .mission-section--full.is-live { min-height: 175vh; }
  .mc-ghost { display: none; }
  .mission-card--full::before { opacity: calc(var(--p) * 0.38); }
  .mission-card--full::after {
    background: linear-gradient(180deg,
      rgba(10, 10, 9, calc(var(--p, 0) * 0.30)) 0%,
      rgba(10, 10, 9, calc(var(--p, 0) * 0.52)) 100%);
  }
  .mission-card--full .mission-card-inner { padding: 0 var(--gutter); }

  /* --- chi siamo: il numero in filigrana dietro i pilastri era troppo presente --- */
  .pillar-num { font-size: 6rem; opacity: 0.055; }

  /* --- tap target: minimo 44px --- */
  .nav-brand {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
  .nav-toggle { width: 44px; height: 44px; margin-right: -0.35rem; }
  .nav.menu-open .nav-links { gap: 0.25rem; }
  .nav.menu-open .nav-links a {
    display: flex;
    align-items: center;
    min-height: 44px;
    font-size: 16px;
  }
  a.contact-value {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    align-self: flex-start;
  }
  .footer-col p, .footer-col a, .footer-col li { font-size: 15px; }
  .footer-col a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
  .footer-col p > a { margin-block: -0.35rem; }
  .footer-bottom a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
  .privacy-content a {
    display: inline-block;
    padding-block: 0.55rem;
  }
  .lightbox-btn { width: 46px; height: 46px; }
}

/* --- 360px: il titolo dei servizi e la didascalia della lastra non devono sfiorare il bordo --- */
@media (max-width: 400px) {
  .service-content h3 { font-size: 1.55rem; }
  .hero-plate-fig figcaption b { font-size: 1.45rem; }
}


/* ============ RIFINITURE DI IMPAGINAZIONE ============
   La filigrana dietro il titolo veniva riportata a opacita' 1 dalla regola
   generica .reveal.in.stagger > * : qui la riporto a livello di texture. */
.advantages-head .advantages-head-mark { opacity: 0.05 !important; }


/* ============================================================
   RITMO — sezioni e margini laterali un po' più ampi, e le poche
   coppie ancora strette (etichetta→valore nei contatti, titolo→
   testo nelle voci servizio, occhiello→titolo in galleria).
   ============================================================ */
:root{
  --pad-section: clamp(6rem, 11.5vw, 10.5rem);
  --gutter: clamp(1.75rem, 4.4vw, 3.5rem);
}
.service-content { gap: 1.4rem; }
.service-item { padding-bottom: clamp(3.6rem, 6vw, 5rem); }
.services-list { gap: clamp(3.6rem, 6vw, 5rem); }
.contact-item { gap: 0.7rem; padding-top: 2rem; }
.gallery-hero .eyebrow { margin-bottom: 2.25rem; }
.gallery-hero-sub { margin-top: 2rem; }
.advantage h3 { margin-bottom: 1.15rem; }
.advantages-head { margin-bottom: clamp(3.6rem, 7vw, 6rem); }
.mission-card h2 { margin: 0 auto 2rem; }
.mission-card .eyebrow { margin-bottom: 2.4rem; }
.page-header .eyebrow { margin-bottom: 2.75rem; }


/* ============================================================
   CTA PIENA — era un bottone "lucido": gradiente dall'alto,
   bordino luminoso interno (inset 0 1px rgba(255,255,255,.2)) e
   alone rosso sotto. Tinta piena, ombra neutra, niente riflessi.
   ============================================================ */
.btn-primary{
  background: var(--accent-fill);
  box-shadow: 0 10px 24px -12px rgba(10,10,9,0.28);
}
.btn-primary:hover{ background: var(--accent-fill-2); }
.btn-primary:not(.mission-btn):hover{
  transform: translateY(-2px);
  box-shadow: 0 16px 30px -14px rgba(10,10,9,0.32);
}
.btn-primary:not(.mission-btn):active{
  transform: translateY(0);
  box-shadow: 0 6px 16px -10px rgba(10,10,9,0.3);
}
/* il bottone delle card CTA: sta sulla carta chiara e poi sul pannello scuro, quindi
   ha colori suoi (PALETTE). Di serie è il pieno rosso col testo bianco sia a card
   chiusa sia a card aperta (Gabriele lo faceva diventare scuro: 3.4:1 sul rosso). */
.btn-primary.mission-btn { background: var(--cta-btn); color: color-mix(in srgb, var(--on-cta-btn-a), var(--on-cta-btn-b) calc(var(--p) * 100%)); }
.btn-primary.mission-btn:hover { background: var(--cta-btn-hover); color: var(--on-cta-hover); }
/* ultime due coppie strette: testo della slide 3D e righe degli orari */
.service-item .service-content { gap: 1.1rem; }
.contact-hours { row-gap: 0.55rem; }


/* ============================================================
   TENDINA SULLE IMMAGINI — la curva --ease (0.65,0.05,…) resta
   quasi ferma per i primi 700ms e poi scatta: sommata a 1,5s di
   durata dava la sensazione che la foto comparisse di colpo.
   Con una curva in decelerazione la tendina parte subito e si
   vede aprirsi. Durata un filo più corta.
   ============================================================ */
.wipe > img, .wipe > iframe,
.feature-media.wipe > img,
.advantage-media.wipe > img,
.pillar-media.wipe > img,
.service-media.wipe > img,
.gallery-tile.wipe > img {
  transition: clip-path 1.05s var(--ease-out), transform 1.2s var(--ease-out), filter 1.2s var(--ease-out);
}

/* =====================================================================
   CTA-card (mission-card) — fix 2026-09-22
   Prima: la variante --inverted finiva su un grigio freddo (--surface)
   con sopra la vignetta scura pensata per il colore pieno → grigio sporco.
   Ora: la variante --inverted è sempre un pannello pieno nel colore scuro
   del brand, con la foto in trasparenza; la vignetta compare solo quando
   la card è scura; lo stato chiaro di partenza è carta calda, non grigio.
   ===================================================================== */
:root { --cta-light: #F4F0EA; } /* --cta-dark e --cta-em-dark: blocco PALETTE */

/* variante normale: parte carta calda, si espande nel colore scuro */
.mission-card { background: color-mix(in srgb, var(--cta-light), var(--cta-dark) calc(var(--p) * 100%)); }
.mission-card h2 em { color: color-mix(in srgb, var(--accent), var(--cta-em-dark) calc(var(--p) * 100%)); }

/* variante --inverted: pannello scuro fisso, niente passaggio al grigio */
.mission-card.mission-card--inverted { background: var(--cta-dark); }
.mission-card--inverted .eyebrow { color: rgba(255, 255, 255, 0.72); }
.mission-card--inverted h2 { color: #fff; }
.mission-card--inverted h2 em { color: var(--cta-em-dark); }
.mission-card--inverted p { color: rgba(255, 255, 255, 0.84); }
.mission-card--inverted .mission-btn { background: #fff; color: var(--ink); }
.mission-card--inverted .mission-btn:hover { background: var(--cta-em-dark); color: var(--on-cta-em); }
.mission-card.mission-card--inverted::before { opacity: 0.28; }
.mission-card.mission-card--inverted::after { background: radial-gradient(80% 70% at 50% 40%, transparent 30%, rgba(10, 10, 9, 0.35)); }
@media (max-width: 760px) {
  .mission-card.mission-card--inverted::before { opacity: 0.2; }
}

/* la foto sotto la CTA si fonde in multiply: scurisce il colore (duotono) invece di slavarlo */
.mission-card::before { mix-blend-mode: multiply; filter: grayscale(1) contrast(1.1); }
.mission-card.mission-card--inverted::before { opacity: 0.55; }
@media (max-width: 760px) { .mission-card.mission-card--inverted::before { opacity: 0.4; } }

/* corsivo leggibile sul pannello bordeaux: --cta-em-dark nel blocco PALETTE */

/* --- fix mobile: niente scroll orizzontale ---------------------------
   1) le colonne del footer erano 1fr (mai sotto la larghezza del contenuto):
      con e-mail lunghe sforavano lo schermo → minmax(0,1fr) + a capo;
   2) la foto dell hero è ingrandita con scale(): serve il ritaglio. */
.footer-cols { grid-template-columns: repeat(auto-fit, minmax(min(11rem, 100%), 1fr)); }
.footer-col { min-width: 0; overflow-wrap: anywhere; }
.hero-plate-fig { overflow: hidden; }
@media (max-width: 900px) { .footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .footer-cols { grid-template-columns: minmax(0, 1fr); } }
html, body { overflow-x: clip; }


/* ============================================================
   CONTRATTO DELLA PIATTAFORMA — aggiunte dello stampo SveaHost
   (templates/README.md). Tutto ciò che il design di Gabriele non
   prevedeva perché il suo sito aveva un nome, un logo e 5 servizi.
   ============================================================ */

/* --- Marchio nel menu: il nome scritto va a capo invece di spingere il menu;
       il logo del cliente con i piatti dello stampo storico (Logo Studio). --- */
.nav-brand { display: inline-flex; align-items: center; min-width: 0; max-width: min(22rem, 30vw); overflow-wrap: anywhere; position: relative; z-index: 2; }
.nav-logo { height: clamp(40px, 3.8vw, 52px); width: auto; max-width: min(220px, 100%); object-fit: contain; display: block; }
.nav-brand img { max-height: 52px; width: auto; }
/* logo chiaro su barra chiara → piatto scuro (logo_is_light o scelta "dark") */
.nav-logo--plate { background: rgba(18, 23, 30, 0.72); padding: 6px 12px; border-radius: 11px; box-sizing: content-box; -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
/* piatto chiaro scelto a mano (lo stile in linea dell'HTML è lo stesso) */
.nav-logo--plate-light { background: rgba(255, 255, 255, 0.94); padding: 6px 12px; border-radius: 11px; box-sizing: content-box; }
.nav-cta { white-space: nowrap; }
.nav-links a:focus-visible, .nav-cta:focus-visible, .nav-brand:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 4px; }

/* --- Menu del telefono: è la stessa lista del menu (app.js la apre), così la voce
       Blog aggiunta dal sistema c'è anche qui. Il bottone diventa una X. --- */
.nav-toggle path { transition: transform 0.35s var(--ease-out); transform-box: view-box; transform-origin: 12px 12px; }
.nav-toggle[aria-expanded="true"] .l1 { transform: rotate(45deg) translateY(4px); }
.nav-toggle[aria-expanded="true"] .l2 { transform: rotate(-45deg) translateY(-4px); }
@media (max-width: 900px) {
  .nav-brand { max-width: calc(100vw - 2 * var(--gutter) - 56px); font-size: 1.35rem; }
  .nav.menu-open { background: rgba(255, 255, 255, 0.97); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); border-bottom-color: var(--line); }
  .nav.menu-open .nav-links { max-height: calc(100vh - 100%); overflow-y: auto; box-shadow: 0 24px 40px -24px rgba(10, 10, 9, 0.25); }
  .nav.menu-open .nav-links a { font-family: var(--font-display); font-size: 1.35rem; font-weight: 400; }
  .nav.menu-open .nav-links a::after { display: none; }
}

/* --- Footer: il marchio del Logo Studio (logo, logo proprio del footer o nome).
       Il footer qui è BIANCO (footerTone "light"): il piatto di contrasto è quello
       SCURO, .footer-logo--ink — lo mette lo stampo (footer_plate "on", o da solo
       per i loghi chiari) e lo scrive il Logo Studio con lo stesso stile in linea
       (var(--footer-ink, #151412), 8px 13px). Il piatto chiaro .footer-logo--plate
       dei footer scuri, se arriva da una pagina vecchia, resta una card bianca con
       un filo d'ombra. --- */
:root { --footer-ink: #151412; }
.footer-logo { height: clamp(48px, 6vw, 76px); width: auto; max-width: min(320px, 70vw); object-fit: contain; display: block; }
.footer-logo--plate { background: rgba(255, 255, 255, 0.94); padding: 8px 13px; border-radius: 12px; box-sizing: content-box; box-shadow: 0 2px 14px rgba(10, 10, 9, 0.12); }
.footer-logo--ink { background: var(--footer-ink, #151412); padding: 8px 13px; border-radius: 12px; box-sizing: content-box; }
.footer-brand { overflow-wrap: anywhere; max-width: 100%; }
.footer-top > .footer-logo, .footer-top > .footer-brand { flex: 0 1 auto; }
.footer-tag { margin: 0; }
.footer-hours span { color: var(--muted); margin-right: 0.3em; }
.footer-bottom span { min-width: 0; }

/* --- Privacy: il testo arriva in markdown (h2, h3, p, ul, ol, li, a, strong). --- */
.privacy-section { padding-top: clamp(3rem, 6vw, 5rem); }
.legal h3 { font-family: var(--font-display); font-size: clamp(1.15rem, 1.7vw, 1.35rem); font-weight: 500; letter-spacing: -0.01em; margin: 2rem 0 0.75rem; color: var(--ink); }
.legal ul, .legal ol { padding-left: 1.5rem; margin-bottom: 1.5rem; }
.legal ul { list-style: disc; }
.legal ol { list-style: decimal; }
.legal li { margin-bottom: 0.5rem; }
.legal li::marker { color: var(--accent); }
.legal > :first-child { margin-top: 0; }
.legal a { overflow-wrap: anywhere; }

/* --- Liste di lunghezza variabile: vantaggi (di solito 3) e pilastri. --- */
@media (min-width: 901px) {
  .advantages-grid { grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); }
  .advantages-grid:not(:has(> :nth-child(3))) { max-width: 62rem; margin-inline: auto; }
}
@media (min-width: 769px) {
  .about-pillars { grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); }
}
.about-pillars { counter-reset: pl; }
.pillar { counter-increment: pl; }
.pillar-num::before { content: counter(pl); }

/* --- Foto che possono mancare: niente riquadri vuoti giganti. --- */
.feature-media:empty { display: none; }
.feature-grid:has(> .feature-media:empty) { grid-template-columns: minmax(0, 1fr); }
.feature-media:empty + .feature-text { margin: 0 auto; max-width: 48rem; }
.hero-feature-tile:not(:has(> .hero-feature-img)) { min-height: 0; background: transparent; justify-items: center; }
@media (max-width: 900px) {
  .hero-feature-tile:not(:has(> .hero-feature-img)) .hero-feature-card { margin-top: 0; }
  .gallery-hero { min-height: 78vh; }
  .gallery-hero-title { font-size: clamp(2.8rem, 14vw, 6rem); }
}

/* --- Prenotazione tramite portale (solo per chi ce l'ha, come nello stampo storico). --- */
.mission-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px; }
.mission-btn-book {
  background: transparent; box-shadow: none;
  color: color-mix(in srgb, var(--ink), #fff calc(var(--p, 0) * 100%));
  border-color: color-mix(in srgb, var(--ink) 45%, #fff calc(var(--p, 0) * 100%));
}
.mission-btn-book-src { opacity: 0.62; font-size: 0.85em; }
@media (max-width: 560px) {
  .mission-actions:has(> :nth-child(2)) { flex-direction: column; align-items: stretch; }
  .mission-actions:has(> :nth-child(2)) > a { justify-content: center; }
}

/* --- Contatti e mappa --- */
.contact-value--mail { font-style: italic; overflow-wrap: anywhere; }
.contact-value { overflow-wrap: anywhere; }
.contact-map-head p { margin-top: 1rem; color: var(--ink-2); font-size: clamp(1rem, 1.2vw, 1.1rem); }
.contact-map iframe { border: 0; }
.contact-map-btn { margin-top: clamp(1.25rem, 2vw, 1.75rem); }

/* --- Titoli lunghi e parole lunghe (tedesco, serbo, nomi composti): mai fuori schermo. --- */
.hero-title, .page-header h1, .contact-text h1, .mission-card h2, .feature-text h2, .advantages-head h2,
.services-intro-card h2, .about-intro-head h2, .service-content h3, .advantage h3, .pillar h3 { overflow-wrap: break-word; hyphens: manual; }
.hero-plate-fig figcaption b { overflow-wrap: anywhere; }

/* --- Lightbox (la crea app.js) e tessere della galleria usabili da tastiera. --- */
.gallery-tile:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.lightbox-img[src=""] { display: none; }

/* --- Pagine del blog (lo shell prende solo nav e footer): la barra è sempre piena
       (app.js mette .solid dove non c'è l'hero) e il contenuto sta sotto la barra. --- */
.svhb--shell { position: relative; z-index: 1; }
/* i titoli del blog con il carattere dei titoli del sito, come nel resto delle pagine */
.svhb--shell .svhb__h1, .svhb--shell .svhb__body h2, .svhb--shell .svhb__faq h2, .svhb--shell .svhb__card h3 { font-family: var(--font-display); font-weight: 400; letter-spacing: -0.02em; }
.svhb--shell .svhb__h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); line-height: 1.04; }

/* --- Agganci delle sezioni (anche per le revisioni: "la sezione dei vantaggi"). --- */
.advantages-section, .about-story, .about-pillars-section, .services-stage { position: relative; }
.page-header--legal { padding-bottom: clamp(3rem, 6vw, 4.5rem); }
.service-cta-label { min-width: 0; }
.arr { flex: 0 0 auto; }
/* .rv segna i blocchi che app.js fa comparire (gli dà .reveal): senza app.js restano visibili */
html:not(.fx) .rv { opacity: 1; transform: none; }
/* e un .reveal scritto nell'HTML (per esempio da una revisione) senza app.js non nasconde niente */
html:not(.fx) .reveal, html:not(.fx) .reveal > *, html:not(.fx) .reveal.stagger > *,
html:not(.fx) .mission-card--full .reveal.stagger > *, html:not(.fx) .hero-feature.reveal .hero-feature-card > * { opacity: 1 !important; transform: none !important; }
@media (prefers-reduced-motion: reduce) {
  html.js .hero-sub, html.js .hero-actions { animation: none; opacity: 1; transform: none; }
}


/* ============================================================
   PALETTE — i colori degli ACCENTI di Gabriele (rosso #c1272d e la sua
   famiglia), tutti qui e solo su :root. Col colore del marchio del cliente
   li riscrive la ricetta (services/generator/src/colori/layout-3.ts) in
   <style id="svh-colori"> subito dopo questo foglio: stessa specificità,
   vince chi viene dopo. I neutri (bianco, carta calda, grigi, nero) restano
   nei blocchi sopra. Questi valori = l'aspetto di Gabriele, identico a prima.
   ============================================================ */
:root {
  --accent: #c1272d;          /* testo e segni in accento sul bianco (menu, corsivi, link, numeri) */
  --accent-2: #9e1f24;        /* accento più scuro (numero del servizio in hover) */
  --accent-rgb: 193, 39, 45;  /* trasparenze dell'accento: riga sullo sfondo, cursore, bagliore del bottone */
  --accent-deep: #6f1418;     /* il pannello scuro delle card CTA */
  --accent-glow: #e4555b;     /* accento sui fondi scuri (lightbox, carosello) e link del footer in hover */
  --accent-fill: #c1272d;     /* i pieni: bottoni, sipario, selezione, cursore */
  --accent-fill-2: #9e1f24;   /* il pieno in hover e il pannello sinistro del sipario */
  --on-accent: #ffffff;       /* il testo sopra i pieni */
  --curtain-3: #6f1418;       /* il pannello destro del sipario */
  --cta-dark: var(--accent-deep);
  --cta-em-dark: #F4B7A8;     /* il corsivo chiaro sul pannello scuro */
  --on-cta-em: var(--ink);    /* il testo del bottone della card scura in hover, sul corsivo chiaro (col bianco era 1.7:1) */
  --cta-btn: var(--accent-fill);        /* il bottone delle card CTA: si deve staccare anche dal pannello scuro */
  --on-cta-btn-a: #ffffff;              /* il suo testo a card chiusa (carta)… */
  --on-cta-btn-b: #ffffff;              /* …e a card aperta (pannello scuro): bianco anche qui (lo scuro sul rosso era 3.4:1) */
  --cta-btn-hover: var(--accent-fill-2);
  --on-cta-hover: #ffffff;
  --ring-rgb: 30, 64, 50;     /* l'alone del campo del modulo a fuoco (com'era: il verde dello stampo storico) */
}
