/* Metal Plastix — foglio di stile unico. Colori dal logo (8.pdf) + accenti cielo e sole. */
@font-face { font-family: "Bitter"; src: url("../font/bitter.woff2") format("woff2"); font-weight: 500 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Bitter"; src: url("../font/bitter-italic.woff2") format("woff2"); font-weight: 500 800; font-style: italic; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../font/inter.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }

:root {
  --verde: #00a650;          /* telaio centrale del logo */
  --verde-2: #60bb46;        /* telaio destro */
  --verde-3: #77c264;        /* telaio sinistro */
  --verde-cta: #00813f;      /* stesso verde, più scuro: testo bianco leggibile */
  --verde-testo: #007a3c;
  --grigio: #58595b;         /* scritta del logo */
  --testo: #222829;
  --tenue: #5b6265;
  --chiaro: #f2f7ee;
  --crema: #fbfaf5;
  --notte: #0f2419;
  --cielo: #2f9fd8;
  --cielo-chiaro: #e4f3fb;
  --sole: #f5b82e;
  --sole-chiaro: #fff3d3;
  --bordo: #e2e7dd;
  --r: 18px;
  --r-s: 12px;
  --ombra: 0 12px 34px rgba(15, 36, 25, .12);
  --ombra-s: 0 4px 14px rgba(15, 36, 25, .10);
  --larg: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --barra: 0px;              /* altezza barra in basso su telefono */
  --telaio: polygon(0 0, 100% 7%, 100% 93%, 0 100%);
}

/* ---------- base e regole telefono (da Freeze System) ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0; background: var(--crema); color: var(--testo);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased;
  padding-bottom: calc(var(--barra) + env(safe-area-inset-bottom, 0px));
  touch-action: manipulation;
}
img, svg { max-width: 100%; display: block; }
img { height: auto; }
a { color: var(--verde-testo); text-underline-offset: 3px; }
a:hover { color: var(--verde-cta); }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--sole); outline-offset: 3px; border-radius: 6px; }
.overflow-x-auto { overflow-x: auto; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.overflow-x-auto::-webkit-scrollbar { display: none; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.salta { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--notte); color: #fff; padding: 10px 16px; border-radius: 10px; }
.salta:focus { top: 12px; color: #fff; }

h1, h2, h3, h4 { font-family: "Bitter", Georgia, serif; color: var(--notte); line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(34px, 6.2vw, 64px); font-weight: 800; }
h2 { font-size: clamp(28px, 4.4vw, 44px); font-weight: 800; }
h3 { font-size: clamp(20px, 2.2vw, 24px); font-weight: 700; }
h1 em, h2 em { font-style: italic; color: var(--verde); }
p { margin: 0 0 1em; }
.lead { font-size: clamp(18px, 2vw, 21px); color: var(--tenue); max-width: 62ch; }

.contenitore { width: 100%; max-width: var(--larg); margin: 0 auto; padding: 0 var(--gutter); }
.sezione { padding: clamp(56px, 9vw, 110px) 0; }
.sezione.stretta { padding: clamp(40px, 6vw, 72px) 0; }
.fondo-chiaro { background: var(--chiaro); }
.fondo-bianco { background: #fff; }
.fondo-cielo { background: linear-gradient(180deg, var(--cielo-chiaro), #f6fbfe); }
.fondo-sole { background: var(--sole-chiaro); }
.fondo-notte { background: var(--notte); color: #e8efe9; }
.fondo-notte h2, .fondo-notte h3 { color: #fff; }
.fondo-notte .lead { color: #c4d3c8; }
.fondo-notte a { color: #b8e6a7; }

/* occhiello con i tre telai */
.occhiello { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--verde-testo); margin: 0 0 14px; }
.occhiello::before { content: ""; width: 34px; height: 22px; flex: none; background: url("../img/telai.svg") center / contain no-repeat; }
.fondo-notte .occhiello { color: #9fdc8a; }
.titolo-sez { max-width: 760px; margin-bottom: clamp(28px, 4vw, 48px); }
.titolo-sez.centro { margin-left: auto; margin-right: auto; text-align: center; }
.titolo-sez.centro .lead { margin-left: auto; margin-right: auto; }

/* ---------- bottoni ---------- */
.bottoni { display: flex; flex-wrap: wrap; gap: 12px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 14px 24px; border-radius: 999px; border: 2px solid transparent; font-weight: 700; font-size: 16px; line-height: 1.1; text-decoration: none; transition: transform .15s ease, background .15s ease, box-shadow .15s ease; }
.btn:hover { transform: translateY(-1px); }
.btn svg { width: 20px; height: 20px; flex: none; }
.btn-verde { background: var(--verde-cta); color: #fff; box-shadow: 0 6px 18px rgba(0, 129, 63, .28); }
.btn-verde:hover { background: #006c35; color: #fff; }
.btn-wa { background: #fff; color: #0b6b3a; border-color: #25d366; }
.btn-wa svg { color: #1fb855; }
.btn-wa:hover { background: #effcf3; color: #0b6b3a; }
.btn-chiaro { background: #fff; color: var(--notte); border-color: var(--bordo); }
.btn-chiaro:hover { color: var(--notte); border-color: var(--verde-2); }
.btn-sole, .fondo-notte .btn-sole { background: var(--sole); color: #2b2100; }
.btn-sole:hover, .fondo-notte .btn-sole:hover { background: #f0a90f; color: #2b2100; }
.fondo-notte .btn-chiaro { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45); }
.link-freccia { font-weight: 700; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.link-freccia::after { content: "→"; transition: transform .15s; }
.link-freccia:hover::after { transform: translateX(4px); }

/* ---------- testata ---------- */
.testata { position: sticky; top: 0; z-index: 40; background: rgba(251, 250, 245, .94); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--bordo); padding-top: env(safe-area-inset-top, 0px); }
.testata .contenitore { display: flex; align-items: center; gap: 20px; min-height: 76px; }
.marchio { display: block; flex: none; }
.marchio img { width: 132px; height: auto; }
.menu { display: flex; gap: 4px; margin-left: auto; }
.menu a { padding: 10px 12px; border-radius: 10px; color: var(--testo); text-decoration: none; font-weight: 600; font-size: 15.5px; }
.menu a:hover { background: var(--chiaro); color: var(--notte); }
.menu a[aria-current="page"] { color: var(--verde-testo); background: var(--chiaro); }
.testata-azioni { display: flex; align-items: center; gap: 10px; }
.tel-testata { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 6px; font-weight: 700; color: var(--notte); text-decoration: none; white-space: nowrap; font-size: 15.5px; }
.tel-testata svg { width: 18px; height: 18px; color: var(--verde); }
.testata .btn { min-height: 44px; padding: 10px 18px; font-size: 15px; }
.apri-menu { display: none; margin-left: auto; width: 48px; height: 48px; border: 1px solid var(--bordo); border-radius: 14px; background: #fff; align-items: center; justify-content: center; color: var(--notte); }
.apri-menu svg { width: 24px; height: 24px; }

/* menu a foglio (telefono) */
.foglio { position: fixed; inset: 0; z-index: 60; display: flex; flex-direction: column; background: var(--crema); padding: calc(env(safe-area-inset-top, 0px) + 14px) var(--gutter) calc(env(safe-area-inset-bottom, 0px) + 20px); max-height: 100dvh; overflow-y: auto; overflow-x: hidden; transform: translateY(-102%); transition: transform .28s ease; visibility: hidden; }
.foglio.aperto { transform: none; visibility: visible; }
.foglio-testa { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
.foglio-testa img { width: 120px; }
.chiudi { width: 48px; height: 48px; border-radius: 14px; border: 1px solid var(--bordo); background: #fff; display: inline-flex; align-items: center; justify-content: center; color: var(--notte); }
.chiudi svg { width: 22px; height: 22px; }
.foglio nav a { display: flex; justify-content: space-between; align-items: center; padding: 16px 4px; border-bottom: 1px solid var(--bordo); font-family: "Bitter", serif; font-weight: 700; font-size: 24px; color: var(--notte); text-decoration: none; }
.foglio nav a::after { content: "→"; color: var(--verde); font-family: "Inter", sans-serif; }
.foglio nav a[aria-current="page"] { color: var(--verde-testo); }
.foglio .contatti-foglio { margin-top: 22px; display: grid; gap: 10px; }
.foglio .contatti-foglio .btn { width: 100%; }
.foglio .piccolo { margin-top: 18px; font-size: 14px; color: var(--tenue); }

/* barra in basso (telefono) */
.barra { display: none; }

/* ---------- apertura (home) ---------- */
.apertura { position: relative; padding: clamp(36px, 6vw, 80px) 0 clamp(48px, 7vw, 96px); overflow: hidden; background:
  radial-gradient(1200px 500px at 85% -10%, rgba(47, 159, 216, .16), transparent 60%),
  radial-gradient(700px 400px at -10% 110%, rgba(119, 194, 100, .18), transparent 60%), var(--crema); }
.apertura .contenitore { display: grid; grid-template-columns: 1fr 1.08fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.apertura h1 { margin-bottom: 20px; }
.apertura .lead { margin-bottom: 28px; }
.garanzie { display: flex; flex-wrap: wrap; gap: 10px 18px; margin-top: 26px; padding: 0; list-style: none; font-size: 15px; font-weight: 600; color: var(--grigio); }
.garanzie li { display: inline-flex; align-items: center; gap: 8px; }
.garanzie svg { width: 20px; height: 20px; color: var(--verde); flex: none; }
.tre-telai { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 3.5%; align-items: center; position: relative; }
.tre-telai .t { position: relative; aspect-ratio: 0.56; clip-path: var(--telaio); padding: 7px; }
.tre-telai .t:nth-child(1) { background: var(--verde-3); transform: translateY(-4%); }
.tre-telai .t:nth-child(2) { background: var(--verde); transform: translateY(5%); }
.tre-telai .t:nth-child(3) { background: var(--verde-2); transform: translateY(-2%); }
.tre-telai .t img { width: 100%; height: 100%; object-fit: cover; clip-path: var(--telaio); }
.tre-telai .bollo { position: absolute; z-index: 2; right: -6px; bottom: -14px; width: clamp(96px, 11vw, 128px); aspect-ratio: 1; border-radius: 50%; background: var(--sole); color: #2b2100; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; font-weight: 800; line-height: 1.05; box-shadow: var(--ombra); transform: rotate(-8deg); }
.bollo b { font-family: "Bitter", serif; font-size: clamp(30px, 3.4vw, 40px); }
.bollo span { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }

/* ---------- numeri ---------- */
.numeri { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.numero { background: #fff; border-radius: var(--r); padding: 24px 22px; border: 1px solid var(--bordo); position: relative; overflow: hidden; }
.numero::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--verde-2); }
.numero:nth-child(2)::before { background: var(--cielo); }
.numero:nth-child(3)::before { background: var(--sole); }
.numero:nth-child(4)::before { background: var(--verde); }
.numero b { display: block; font-family: "Bitter", serif; font-size: clamp(34px, 4.4vw, 52px); font-weight: 800; color: var(--notte); line-height: 1; margin-bottom: 8px; }
.numero span { color: var(--tenue); font-size: 15px; font-weight: 600; }

/* ---------- prodotti (griglia) ---------- */
.griglia-prodotti { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.scheda { position: relative; display: flex; flex-direction: column; background: #fff; border-radius: var(--r); overflow: hidden; border: 1px solid var(--bordo); text-decoration: none; color: var(--testo); transition: transform .2s ease, box-shadow .2s ease; }
.scheda:hover { transform: translateY(-4px); box-shadow: var(--ombra); color: var(--testo); }
.scheda .foto { aspect-ratio: 4 / 3; overflow: hidden; background: var(--chiaro); }
.scheda .foto img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.scheda:hover .foto img { transform: scale(1.05); }
.scheda .corpo { padding: 18px 18px 20px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.scheda h3 { font-size: 20px; margin: 0; }
.scheda p { margin: 0; color: var(--tenue); font-size: 15px; line-height: 1.5; }
.scheda .freccia { margin-top: auto; padding-top: 8px; font-weight: 700; color: var(--verde-testo); font-size: 15px; }
.scheda.grande { grid-column: span 2; }
.scheda.grande .foto { aspect-ratio: 16 / 9; }

/* ---------- scegli il colore ---------- */
.colore { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.finestra-demo { position: relative; max-width: 460px; margin: 0 auto; width: 100%; }
.vano { position: relative; aspect-ratio: 0.86; padding: 6%; background: #f4ede1; border-radius: 6px; box-shadow: inset 0 0 0 10px #ece2d2, var(--ombra); }
.paesaggio { position: absolute; inset: 6%; overflow: hidden; background: linear-gradient(180deg, #8fd0f2 0%, #cdeefc 58%, #f6e8c8 100%); }
.paesaggio svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.telaio-fisso { position: absolute; inset: 6%; border: 14px solid var(--colore, #fffaf6); border-image: var(--legno, none) 30% / 14px round; box-shadow: 0 2px 6px rgba(0, 0, 0, .18), inset 0 0 0 1px rgba(0, 0, 0, .08); perspective: 900px; display: grid; grid-template-columns: 1fr 1fr; }
.anta { position: relative; border: 12px solid var(--colore, #fffaf6); border-image: var(--legno, none) 30% / 12px round; transform: perspective(700px) rotateY(0deg); transform-origin: left center; transition: transform .9s cubic-bezier(.2, .7, .2, 1); background: linear-gradient(135deg, rgba(255, 255, 255, .28), rgba(255, 255, 255, 0) 40%, rgba(255, 255, 255, .12) 70%, rgba(255, 255, 255, 0)); box-shadow: 0 0 0 1px rgba(0, 0, 0, .12); }
.anta + .anta { transform-origin: right center; }
.anta .maniglia { position: absolute; top: 46%; right: -9px; width: 6px; height: 34px; border-radius: 4px; background: linear-gradient(#e9e9e9, #a9a9a9); box-shadow: 0 1px 2px rgba(0, 0, 0, .3); }
.anta + .anta .maniglia { display: none; }
.finestra-demo.aperta .anta:first-child { transform: perspective(700px) rotateY(-58deg); }
.finestra-demo.aperta .anta + .anta { transform: perspective(700px) rotateY(42deg); }
.davanzale { height: 18px; margin: -4px -3% 0; background: linear-gradient(#ebe6dc, #d4ccbd); border-radius: 3px; box-shadow: 0 8px 16px rgba(0, 0, 0, .12); }
.tinte { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; margin: 22px 0 14px; padding: 0; list-style: none; }
.tinte button { width: 100%; aspect-ratio: 1; border-radius: 12px; border: 2px solid rgba(0, 0, 0, .08); background-size: cover; background-position: center; box-shadow: inset 0 0 0 3px #fff; transition: transform .15s; min-height: 44px; }
.tinte button:hover { transform: scale(1.06); }
.tinte button[aria-pressed="true"] { border-color: var(--verde); box-shadow: inset 0 0 0 3px #fff, 0 0 0 3px rgba(0, 166, 80, .25); }
.tinta-nome { font-family: "Bitter", serif; font-size: 26px; font-weight: 800; color: var(--notte); margin: 0; }
.tinta-veka { color: var(--tenue); font-size: 14px; margin: 0 0 18px; }

/* ---------- perché noi ---------- */
.punti { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.punto { background: #fff; border-radius: var(--r); padding: 26px 22px; border: 1px solid var(--bordo); }
.punto .ico { width: 54px; height: 54px; border-radius: 16px; display: flex; align-items: center; justify-content: center; margin-bottom: 16px; background: var(--chiaro); color: var(--verde); }
.punto:nth-child(2) .ico { background: var(--cielo-chiaro); color: var(--cielo); }
.punto:nth-child(3) .ico { background: var(--sole-chiaro); color: #c98a00; }
.punto .ico svg { width: 28px; height: 28px; }
.punto h3 { font-size: 20px; margin-bottom: 8px; }
.punto p { color: var(--tenue); font-size: 15.5px; margin: 0; }

/* ---------- lavori (anteprima home) ---------- */
.mosaico { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: clamp(150px, 18vw, 230px); gap: 12px; }
.mosaico a { position: relative; overflow: hidden; border-radius: var(--r-s); display: block; background: var(--chiaro); }
.mosaico a:nth-child(1) { grid-column: span 2; grid-row: span 2; }
.mosaico a:nth-child(4) { grid-row: span 2; }
.mosaico img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.mosaico a:hover img { transform: scale(1.05); }
.mosaico span { position: absolute; left: 10px; bottom: 10px; right: 10px; color: #fff; font-size: 14px; font-weight: 600; text-shadow: 0 1px 6px rgba(0, 0, 0, .6); }
.riga-fine { display: flex; justify-content: space-between; align-items: end; gap: 20px; flex-wrap: wrap; margin-bottom: 28px; }
.riga-fine .titolo-sez { margin-bottom: 0; }

/* ---------- restauro (scuro) ---------- */
.restauro { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(28px, 5vw, 70px); align-items: center; }
.restauro .foto-doppia { display: grid; grid-template-columns: 1.2fr 1fr; gap: 14px; align-items: end; }
.restauro .foto-doppia div { clip-path: var(--telaio); overflow: hidden; }
.restauro .foto-doppia div:first-child { aspect-ratio: .72; }
.restauro .foto-doppia div:last-child { aspect-ratio: .82; margin-bottom: 12%; }
.restauro .foto-doppia img { width: 100%; height: 100%; object-fit: cover; }
.elenco-spunte { list-style: none; padding: 0; margin: 0 0 26px; display: grid; gap: 10px; }
.elenco-spunte li { position: relative; padding-left: 32px; }
.elenco-spunte li::before { content: ""; position: absolute; left: 0; top: .32em; width: 20px; height: 20px; border-radius: 50%; background: var(--verde-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 13px no-repeat; }

/* ---------- passi ---------- */
.passi { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; counter-reset: passo; list-style: none; padding: 0; margin: 0; }
.passi li { position: relative; background: #fff; border-radius: var(--r); padding: 26px 22px 24px; border: 1px solid var(--bordo); }
.passi li::before { counter-increment: passo; content: counter(passo); display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; background: var(--verde); color: #fff; font-family: "Bitter", serif; font-weight: 800; font-size: 20px; margin-bottom: 14px; }
.passi li:nth-child(2)::before { background: var(--cielo); }
.passi li:nth-child(3)::before { background: var(--sole); color: #2b2100; }
.passi li:nth-child(4)::before { background: var(--verde-2); }
.passi h3 { font-size: 19px; margin-bottom: 6px; }
.passi p { margin: 0; color: var(--tenue); font-size: 15.5px; }

/* ---------- marchi (nastro che scorre) ---------- */
.nastro { overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.nastro ul { display: flex; gap: 18px; width: max-content; padding: 6px 0; margin: 0; list-style: none; animation: scorri 46s linear infinite; }
.nastro:hover ul { animation-play-state: paused; }
.nastro li { flex: none; height: 92px; padding: 16px 22px; background: #fff; border: 1px solid var(--bordo); border-radius: 14px; display: flex; align-items: center; }
.nastro img { height: 58px; width: auto; max-width: 180px; object-fit: contain; }
@keyframes scorri { to { transform: translateX(calc(-50% - 9px)); } }

/* ---------- invito finale ---------- */
.invito { position: relative; overflow: hidden; border-radius: 28px; padding: clamp(32px, 5vw, 64px); background: linear-gradient(120deg, var(--verde-cta), #10924c 55%, #5fb547); color: #fff; display: grid; grid-template-columns: 1.3fr 1fr; gap: 28px; align-items: center; }
.invito h2 { color: #fff; margin-bottom: 10px; }
.invito p { color: #e7f7e6; margin: 0; font-size: 18px; }
.invito .bottoni { justify-content: flex-end; }
.invito .btn-chiaro { border-color: transparent; }
.invito::after { content: ""; position: absolute; right: -40px; top: -40px; width: 220px; height: 220px; border-radius: 50%; background: var(--sole); opacity: .9; z-index: 0; }
.invito > * { position: relative; z-index: 1; }

/* ---------- testata pagine interne ---------- */
.testa-pagina { padding: clamp(36px, 6vw, 80px) 0 clamp(28px, 4vw, 48px); background:
  radial-gradient(900px 380px at 90% -20%, rgba(47, 159, 216, .14), transparent 60%), var(--crema); }
.briciole { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 0 0 18px; font-size: 14px; color: var(--tenue); }
.briciole li + li::before { content: "/"; margin-right: 6px; color: #b9c0b4; }
.briciole a { color: var(--tenue); text-decoration: none; }
.testa-pagina .lead { margin-bottom: 0; }

/* ---------- azienda ---------- */
.storia { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.storia .foto-grande { border-radius: var(--r); overflow: hidden; box-shadow: var(--ombra); }
.squadra { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.persona { background: #fff; border-radius: var(--r); overflow: hidden; border: 1px solid var(--bordo); }
.persona .foto { aspect-ratio: 1; overflow: hidden; background: var(--chiaro); }
.persona img { width: 100%; height: 100%; object-fit: cover; }
.persona .corpo { padding: 14px 16px 18px; }
.persona h3 { font-size: 18px; margin: 0 0 4px; }
.persona p { margin: 0; font-size: 14.5px; color: var(--tenue); line-height: 1.4; }
.veka { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.veka .foto-doppia { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.veka .foto-doppia img { border-radius: var(--r-s); aspect-ratio: 1; object-fit: cover; width: 100%; }
.citazione { font-family: "Bitter", serif; font-style: italic; font-size: clamp(20px, 2.4vw, 26px); line-height: 1.35; color: var(--notte); border-left: 5px solid var(--sole); padding-left: 18px; margin: 18px 0 22px; }
.certificati { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.certificato { background: #fff; border: 1px solid var(--bordo); border-radius: var(--r); padding: 22px; display: grid; grid-template-columns: 64px 1fr; gap: 16px; align-items: start; }
.certificato .sigillo { width: 64px; height: 64px; border-radius: 50%; border: 3px solid var(--cielo); display: flex; align-items: center; justify-content: center; text-align: center; font-weight: 800; font-size: 12px; line-height: 1.05; color: #1874a8; background: var(--cielo-chiaro); }
.certificato h3 { font-size: 18px; margin: 0 0 4px; }
.certificato p { margin: 0; color: var(--tenue); font-size: 15px; line-height: 1.5; }
.certificato.invito-cert { border-style: dashed; border-color: var(--verde-2); background: var(--chiaro); }
.certificato.invito-cert .sigillo { border-color: var(--verde); background: #fff; color: var(--verde-testo); }
.lavora { display: grid; grid-template-columns: 1.2fr 1fr; gap: 28px; align-items: center; background: #fff; border-radius: 24px; border: 1px solid var(--bordo); padding: clamp(26px, 4vw, 48px); }

/* ---------- prodotti (pagina) ---------- */
.indice { position: sticky; top: 76px; z-index: 30; background: rgba(251, 250, 245, .96); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border-bottom: 1px solid var(--bordo); }
.indice ul { display: flex; gap: 8px; list-style: none; margin: 0; padding: 12px var(--gutter); max-width: var(--larg); margin: 0 auto; }
.indice a { display: inline-flex; align-items: center; min-height: 40px; padding: 8px 16px; border-radius: 999px; background: #fff; border: 1px solid var(--bordo); color: var(--testo); text-decoration: none; font-weight: 600; font-size: 15px; white-space: nowrap; }
.indice a.attivo { background: var(--notte); color: #fff; border-color: var(--notte); }
.prodotto { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(26px, 5vw, 64px); align-items: center; padding: clamp(44px, 7vw, 84px) 0; border-bottom: 1px solid var(--bordo); scroll-margin-top: 150px; }
.prodotto:last-child { border-bottom: 0; }
.prodotto:nth-of-type(even) .prodotto-foto { order: 2; }
.prodotto-foto { position: relative; }
.prodotto-foto .cornice { clip-path: var(--telaio); padding: 8px; background: var(--verde-2); }
.prodotto:nth-of-type(3n+2) .prodotto-foto .cornice { background: var(--verde); }
.prodotto:nth-of-type(3n) .prodotto-foto .cornice { background: var(--verde-3); }
.prodotto-foto img { width: 100%; aspect-ratio: 4 / 3.3; object-fit: cover; clip-path: var(--telaio); background: #fff; }
.prodotto .etichetta { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--verde-testo); background: var(--chiaro); padding: 6px 12px; border-radius: 999px; margin-bottom: 12px; }
.prodotto h2 { font-size: clamp(28px, 3.6vw, 40px); }
.prodotto .nota { font-size: 14px; color: var(--tenue); margin-top: -6px; }
.extra { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 0 0 22px; }
.extra figure { margin: 0; background: #fff; border: 1px solid var(--bordo); border-radius: var(--r-s); overflow: hidden; }
.extra img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.extra figcaption { font-size: 14px; padding: 8px 12px; color: var(--tenue); }
.pellicole { max-width: 880px; margin: 8px auto 0; border-radius: var(--r); overflow: hidden; border: 1px solid var(--bordo); background: #fff; }
.pellicole figcaption { padding: 12px 16px; font-size: 14px; color: var(--tenue); }

/* ---------- galleria lavori ---------- */
.filtri { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 24px; }
.filtri button { min-height: 44px; padding: 10px 18px; border-radius: 999px; border: 1px solid var(--bordo); background: #fff; font-weight: 700; color: var(--testo); }
.filtri button[aria-pressed="true"] { background: var(--notte); color: #fff; border-color: var(--notte); }
.filtri button span { opacity: .65; font-weight: 600; margin-left: 4px; }
.galleria { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.galleria button { position: relative; padding: 0; border: 0; border-radius: var(--r-s); overflow: hidden; aspect-ratio: 1; background: var(--chiaro); }
.galleria img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.galleria button:hover img { transform: scale(1.05); }
.galleria button[hidden] { display: none; }
.galleria .cat { position: absolute; left: 8px; top: 8px; background: rgba(15, 36, 25, .78); color: #fff; font-size: 12px; font-weight: 700; padding: 4px 9px; border-radius: 999px; }
.lightbox { position: fixed; inset: 0; z-index: 80; background: rgba(8, 18, 12, .94); display: none; flex-direction: column; align-items: center; justify-content: center; padding: calc(env(safe-area-inset-top, 0px) + 60px) 12px calc(env(safe-area-inset-bottom, 0px) + 70px); height: 100dvh; }
.lightbox.aperto { display: flex; }
.lightbox figure { margin: 0; max-width: min(1100px, 100%); display: flex; flex-direction: column; align-items: center; min-height: 0; }
.lightbox img { max-width: 100%; max-height: calc(100dvh - 180px); object-fit: contain; border-radius: 8px; }
.lightbox figcaption { color: #e3ebe5; font-size: 15px; margin-top: 12px; text-align: center; }
.lightbox .lb-btn { position: absolute; width: 52px; height: 52px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; display: flex; align-items: center; justify-content: center; }
.lightbox .lb-btn svg { width: 24px; height: 24px; }
.lightbox .lb-chiudi { top: calc(env(safe-area-inset-top, 0px) + 10px); right: 12px; }
.lightbox .lb-prec { left: 12px; top: 50%; transform: translateY(-50%); }
.lightbox .lb-succ { right: 12px; top: 50%; transform: translateY(-50%); }
.lightbox .lb-conta { position: absolute; top: calc(env(safe-area-inset-top, 0px) + 22px); left: 18px; color: #c5d3c9; font-size: 14px; font-weight: 600; }

/* ---------- contatti ---------- */
.contatti { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(26px, 4vw, 56px); align-items: start; }
.recapiti { display: grid; gap: 12px; }
.recapito { display: grid; grid-template-columns: 52px 1fr; gap: 14px; align-items: center; background: #fff; border: 1px solid var(--bordo); border-radius: var(--r); padding: 16px 18px; text-decoration: none; color: var(--testo); }
a.recapito:hover { border-color: var(--verde-2); color: var(--testo); box-shadow: var(--ombra-s); }
.recapito .ico { width: 52px; height: 52px; border-radius: 15px; background: var(--chiaro); color: var(--verde); display: flex; align-items: center; justify-content: center; }
.recapito .ico svg { width: 24px; height: 24px; }
.recapito.wa .ico { background: #e7f9ee; color: #1fb855; }
.recapito small { display: block; color: var(--tenue); font-size: 13.5px; font-weight: 600; }
.recapito b { display: block; font-size: 18px; color: var(--notte); overflow-wrap: anywhere; }
.modulo { background: #fff; border: 1px solid var(--bordo); border-radius: 24px; padding: clamp(22px, 3.5vw, 36px); box-shadow: var(--ombra-s); scroll-margin-top: 100px; }
.modulo h2 { font-size: clamp(26px, 3vw, 32px); }
.campi { display: grid; grid-template-columns: 1fr; gap: 14px; }
.campo label { display: block; font-weight: 700; font-size: 15px; margin-bottom: 6px; color: var(--notte); }
.campo label span { font-weight: 500; color: var(--tenue); }
.campo input, .campo select, .campo textarea { width: 100%; min-width: 0; font: inherit; font-size: 16px; padding: 13px 14px; border-radius: 12px; border: 1.5px solid #cfd6cb; background: #fbfcfa; color: var(--testo); appearance: none; -webkit-appearance: none; }
.campo select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2358595b' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 18px; padding-right: 40px; }
.campo textarea { min-height: 130px; resize: vertical; }
.campo input:focus, .campo select:focus, .campo textarea:focus { outline: none; border-color: var(--verde); box-shadow: 0 0 0 4px rgba(0, 166, 80, .15); background: #fff; }
.consenso { display: grid; grid-template-columns: 24px 1fr; gap: 12px; align-items: start; font-size: 14.5px; color: var(--tenue); }
.consenso input { width: 24px; height: 24px; margin: 1px 0 0; accent-color: var(--verde-cta); }
.esca { position: absolute; left: -5000px; }
.esito { display: none; margin-top: 14px; padding: 14px 16px; border-radius: 12px; font-weight: 600; }
.esito.ok { display: block; background: #e6f6ea; color: #0b6b3a; }
.esito.errore { display: block; background: #fdecec; color: #9b1c1c; }
.modulo .btn { width: 100%; margin-top: 4px; }
.mappa { margin-top: 18px; border-radius: var(--r); overflow: hidden; border: 1px solid var(--bordo); background: linear-gradient(135deg, var(--chiaro), var(--cielo-chiaro)); aspect-ratio: 16 / 10; position: relative; }
.mappa iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.mappa .mappa-invito { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center; padding: 20px; }
.mappa .mappa-invito p { margin: 0; font-size: 14px; color: var(--tenue); max-width: 34ch; }
.social { display: flex; gap: 10px; margin-top: 12px; }
.social a { width: 48px; height: 48px; border-radius: 14px; background: #fff; border: 1px solid var(--bordo); display: inline-flex; align-items: center; justify-content: center; color: var(--notte); }
.social svg { width: 22px; height: 22px; }

/* ---------- testi lunghi (privacy) ---------- */
.testo-lungo { max-width: 760px; }
.testo-lungo h2 { font-size: clamp(22px, 2.6vw, 28px); margin-top: 1.6em; }
.testo-lungo ul { padding-left: 1.2em; }
.testo-lungo li { margin-bottom: .4em; }

/* ---------- piè di pagina ---------- */
.piede { background: var(--notte); color: #c9d6cd; padding: clamp(48px, 7vw, 80px) 0 28px; margin-top: 0; }
.piede a { color: #e9f3ec; text-decoration: none; }
.piede a:hover { color: #b8e6a7; text-decoration: underline; }
.piede-griglia { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 32px; }
.piede img.logo { width: 170px; margin-bottom: 16px; }
.piede h3 { color: #fff; font-family: "Inter", sans-serif; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; margin: 6px 0 14px; }
.piede .social a { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .2); color: #fff; }
.piede .social a:hover { background: rgba(255, 255, 255, .16); text-decoration: none; }
.piede ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: 15.5px; }
.piede p { font-size: 15px; }
.piede-fondo { margin-top: 40px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .12); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 13.5px; color: #93a79a; }
.piede-fondo a { color: #c9d6cd; }
.telai-fascia { display: flex; height: 8px; }
.telai-fascia i { flex: 1; }
.telai-fascia i:nth-child(1) { background: var(--verde-3); } .telai-fascia i:nth-child(2) { background: var(--verde); } .telai-fascia i:nth-child(3) { background: var(--verde-2); } .telai-fascia i:nth-child(4) { background: var(--cielo); } .telai-fascia i:nth-child(5) { background: var(--sole); }

/* ---------- comparsa leggera ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js .appare { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
  .js .appare.visto { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .nastro ul { animation: none; flex-wrap: wrap; width: auto; }
  .anta { transition: none; }
}

/* ---------- tablet ---------- */
@media (max-width: 1100px) {
  .menu a { padding: 10px 8px; font-size: 15px; }
  .tel-testata span { display: none; }
  .griglia-prodotti { grid-template-columns: repeat(4, 1fr); }
  .griglia-prodotti .scheda:nth-child(9), .griglia-prodotti .scheda:nth-child(10) { grid-column: span 2; }
  .griglia-prodotti .scheda:nth-child(9) .foto, .griglia-prodotti .scheda:nth-child(10) .foto { aspect-ratio: 16 / 7; }
  .squadra { grid-template-columns: repeat(3, 1fr); }
  .piede-griglia { grid-template-columns: 1fr 1fr; }
}

/* ---------- telefono ---------- */
@media (max-width: 899px) {
  :root { --barra: 64px; }
  body { font-size: 16.5px; }
  h1 { font-size: clamp(32px, 9vw, 44px); }
  h2 { font-size: clamp(26px, 7vw, 34px); }
  .menu, .testata-azioni { display: none; }
  .apri-menu { display: inline-flex; }
  .testata .contenitore { min-height: 64px; }
  .marchio img { width: 112px; }
  html { scroll-padding-top: 80px; scroll-padding-bottom: calc(var(--barra) + 24px + env(safe-area-inset-bottom, 0px)); }
  .barra { display: grid; grid-template-columns: 1fr 1fr 1.25fr; position: fixed; z-index: 50; left: 0; right: 0; bottom: 0; background: #fff; border-top: 1px solid var(--bordo); padding: 8px 10px calc(8px + env(safe-area-inset-bottom, 0px)); gap: 8px; box-shadow: 0 -6px 20px rgba(15, 36, 25, .08); }
  .barra a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 48px; border-radius: 12px; text-decoration: none; font-weight: 700; font-size: 13px; color: var(--notte); }
  .barra a svg { width: 22px; height: 22px; }
  .barra a.wa svg { color: #1fb855; }
  .barra a.tel svg { color: var(--verde); }
  .barra a.prev { background: var(--verde-cta); color: #fff; flex-direction: row; gap: 8px; font-size: 15px; }
  .foglio-aperto .barra { visibility: hidden; }
  .apertura .contenitore { grid-template-columns: 1fr; }
  .tre-telai { max-width: 460px; margin: 6px auto 0; width: 100%; }
  .apertura .bottoni .btn { flex: 1 1 100%; }
  .numeri { grid-template-columns: 1fr 1fr; gap: 12px; }
  .numero { padding: 18px 16px; }
  .griglia-prodotti { grid-template-columns: 1fr 1fr; gap: 12px; }
  .griglia-prodotti .scheda:nth-child(9), .griglia-prodotti .scheda:nth-child(10) { grid-column: span 1; }
  .griglia-prodotti .scheda:nth-child(9) .foto, .griglia-prodotti .scheda:nth-child(10) .foto { aspect-ratio: 4 / 3; }
  .scheda .corpo { padding: 14px 14px 16px; }
  .scheda h3 { font-size: 17.5px; }
  .scheda p { font-size: 14px; }
  .colore, .restauro, .storia, .veka, .contatti, .lavora, .invito { grid-template-columns: 1fr; }
  .tinte { grid-template-columns: repeat(6, 1fr); gap: 8px; }
  .punti, .passi { grid-template-columns: 1fr 1fr; gap: 12px; }
  .punto, .passi li { padding: 20px 16px; }
  .mosaico { grid-template-columns: 1fr 1fr; grid-auto-rows: 150px; gap: 8px; }
  .mosaico a:nth-child(4) { grid-row: span 1; }
  .mosaico a:nth-child(n+6) { display: none; }
  .restauro .foto-doppia { order: -1; }
  .invito .bottoni { justify-content: flex-start; }
  .invito .btn { flex: 1 1 100%; }
  .squadra { grid-template-columns: 1fr 1fr; gap: 12px; }
  .indice { top: 64px; }
  .prodotto { grid-template-columns: 1fr; gap: 22px; scroll-margin-top: 130px; }
  .prodotto:nth-of-type(even) .prodotto-foto { order: 0; }
  .prodotto .bottoni .btn { flex: 1 1 100%; }
  .galleria { grid-template-columns: 1fr 1fr 1fr; gap: 6px; }
  .galleria .cat { display: none; }
  .lightbox .lb-prec, .lightbox .lb-succ { top: auto; bottom: calc(env(safe-area-inset-bottom, 0px) + 12px); transform: none; }
  .lightbox .lb-prec { left: calc(50% - 64px); }
  .lightbox .lb-succ { right: calc(50% - 64px); }
  .piede-griglia { grid-template-columns: 1fr; gap: 26px; }
  .extra { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 420px) {
  .tinte { grid-template-columns: repeat(4, 1fr); }
  .punti, .passi { grid-template-columns: 1fr; }
  .galleria { grid-template-columns: 1fr 1fr; }
  .squadra .persona h3 { font-size: 16px; }
}
/* campi data/ora su iOS (regola Freeze System) */
@supports (-webkit-touch-callout: none) {
  input[type="date"], input[type="datetime-local"], input[type="time"], input[type="month"] { appearance: none; min-width: 0; }
  input::-webkit-date-and-time-value { text-align: left; margin: 0; }
}
.certificato .sigillo svg { width: 26px; height: 26px; }
