
/* ── FONT IN LOCALE (niente richieste a Google = niente problemi GDPR) ── */
@font-face { font-family: 'Playfair Display'; font-style: normal; font-weight: 400; font-display: swap; src: url(../fonts/playfair-display-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'Playfair Display'; font-style: italic; font-weight: 400; font-display: swap; src: url(../fonts/playfair-display-latin-400-italic.woff2) format('woff2'); }
@font-face { font-family: 'Playfair Display'; font-style: normal; font-weight: 500; font-display: swap; src: url(../fonts/playfair-display-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'Lato'; font-style: normal; font-weight: 300; font-display: swap; src: url(../fonts/lato-latin-300-normal.woff2) format('woff2'); }
@font-face { font-family: 'Lato'; font-style: normal; font-weight: 400; font-display: swap; src: url(../fonts/lato-latin-400-normal.woff2) format('woff2'); }

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

:root {
  --ink: #111111;
  --paper: #c8c4bc;
  --paper-2: #bfbbb3;
  --placeholder: #d6d3cc;
  --muted: #4a463f;          /* 5.4:1 sul fondo — prima era 3.2:1, illeggibile */
  --line: #a9a59d;
  --serif: 'Playfair Display', Georgia, serif;
  --sans: 'Lato', system-ui, sans-serif;
  --nav-h: 64px;
  --gutter: 40px;
}

html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  font-weight: 300;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
body.no-scroll { overflow: hidden; }

a { color: inherit; }
:focus-visible { outline: 1px solid var(--ink); outline-offset: 4px; }
img { display: block; max-width: 100%; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 12px; z-index: 999; background: var(--ink); color: var(--paper); padding: 8px 14px; }


/* ── LOGO MACCHINA FOTOGRAFICA ── */
.nav-logo { display: inline-flex; align-items: center; gap: 12px; }
.nav-logo .cam { width: 30px; height: auto; color: var(--ink); flex-shrink: 0; }
.cam-iris { transform-origin: 50px 49px; transform: scale(0); }
.cam-lines circle:first-of-type { fill: var(--paper); }
/* scatto al passaggio del mouse sul logo */
.nav-logo:hover .cam-iris, .nav-logo:focus-visible .cam-iris { animation: shutter .32s ease-in-out; }
@keyframes shutter { 0% { transform: scale(0); } 45% { transform: scale(1); } 100% { transform: scale(0); } }

/* intro: la macchina si disegna, scatta, flash — una volta per visita */
.intro {
  position: fixed; inset: 0; z-index: 1000; background: var(--paper);
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.intro[hidden] { display: none; }
.intro .cam { width: min(150px, 36vw); height: auto; color: var(--ink); }
.intro .cam-lines path, .intro .cam-lines circle { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw .9s cubic-bezier(.6,.1,.3,1) forwards; }
.intro .cam-lines > :nth-child(2) { animation-delay: .15s; }
.intro .cam-lines > :nth-child(3) { animation-delay: .25s; }
.intro .cam-lines > :nth-child(4) { animation-delay: .3s; }
.intro .cam-lines > :nth-child(5) { animation-delay: .2s; }
.intro .cam-lines > :nth-child(6) { animation-delay: .35s; }
.intro .cam-shadow { transform-origin: 50px 80px; transform: scaleX(0); animation: grow .6s .5s ease-out forwards; }
.intro .cam-iris { animation: shutter .3s 1.15s ease-in-out; }
.intro::after { content: ''; position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; animation: flash .55s 1.3s ease-out; }
.intro.out { animation: introOut .5s 1.55s ease forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes grow { to { transform: scaleX(1); } }
@keyframes flash { 0% { opacity: 0; } 15% { opacity: .9; } 100% { opacity: 0; } }
@keyframes introOut { to { opacity: 0; visibility: hidden; } }

/* ── NAV ── */
.site-nav {
  position: sticky; top: 0; z-index: 100;
  height: var(--nav-h);
  background: var(--paper);
  border-bottom: 0.5px solid var(--line);
  padding: 0 var(--gutter);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.nav-logo {
  font-family: var(--serif); font-size: 17px; font-weight: 400;
  text-decoration: none; white-space: nowrap;
}
.nav-links { display: flex; gap: 32px; list-style: none; align-items: center; }
.nav-links a, .mobile-menu .small {
  font-size: 12.5px; font-weight: 400; letter-spacing: 0.08em; text-transform: uppercase;
  text-decoration: none; white-space: nowrap;
  padding: 6px 0;
  border-bottom: 0.5px solid transparent;
  transition: border-color .2s;
}
.nav-links a:hover { border-color: var(--line); }
.nav-links a[aria-current="page"] { border-color: var(--ink); }

.menu-toggle {
  display: none; background: none; border: none; cursor: pointer;
  width: 40px; height: 40px; margin-right: -8px;
  flex-direction: column; justify-content: center; align-items: center; gap: 6px;
}
.menu-toggle span { display: block; width: 22px; height: 1px; background: var(--ink); transition: transform .25s, opacity .25s; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  position: fixed; top: var(--nav-h); left: 0; right: 0; bottom: 0; z-index: 99;
  background: var(--paper);
  padding: 40px 24px;
  display: flex; flex-direction: column; gap: 22px;
  overflow-y: auto;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu a.big { font-family: var(--serif); font-size: 30px; text-decoration: none; line-height: 1.15; }
.mobile-menu a.big[aria-current="page"] { font-style: italic; }
.mobile-menu .social { margin-top: auto; padding-top: 24px; }

/* ── MAIN ── */
main { flex: 1; }
.view[hidden] { display: none; }
.view { animation: fade .35s ease; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.wrap { padding: 48px var(--gutter) 64px; max-width: 1400px; margin: 0 auto; }

.eyebrow { font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 400; }
.page-title { font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 4vw, 40px); line-height: 1.15; margin: 10px 0 12px; }
.page-intro { font-family: var(--serif); font-style: italic; font-size: 16px; color: var(--muted); max-width: 560px; line-height: 1.6; margin-bottom: 40px; }

/* ── HOME ── */
.manifesto { padding: 96px var(--gutter) 72px; max-width: 1400px; margin: 0 auto; }
.manifesto h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(36px, 6.2vw, 84px); line-height: 1.05; letter-spacing: -0.015em; max-width: 13em; }
.manifesto h1 em { font-style: italic; }
.manifesto .scroll { display: inline-block; margin-top: 40px; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; font-weight: 400; text-decoration: none; }
.manifesto .scroll:hover { text-decoration: underline; text-underline-offset: 4px; }
#storie { scroll-margin-top: calc(var(--nav-h) + 16px); }
/* home = chi sono */
.hello {
  display: grid; grid-template-columns: minmax(260px, 420px) 1fr; gap: 72px; align-items: center;
  max-width: 1200px; margin: 0 auto; padding: 72px var(--gutter) 88px;
  min-height: calc(100vh - var(--nav-h) - 70px);
}
.hello-photo { aspect-ratio: 3/4; position: relative; overflow: hidden; background: var(--placeholder); }
.hello-photo img { width: 100%; height: 100%; object-fit: cover; }
.hello h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(34px, 4.6vw, 60px); line-height: 1.06; letter-spacing: -0.015em; margin-bottom: 32px; }
.hello h1 em { font-style: italic; }
.hello p { font-size: 16.5px; line-height: 1.8; max-width: 540px; margin-bottom: 16px; }
.hello .sign { font-family: var(--serif); font-style: italic; font-size: 19px; margin-top: 8px; }
.hello .actions { margin-top: 36px; display: flex; align-items: center; flex-wrap: wrap; gap: 16px 28px; }
.hello .actions .cta { margin-top: 0; }

/* porte (pagina portfolio) */
.doors { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.door { text-decoration: none; display: block; }
.door-media { position: relative; aspect-ratio: 4/5; overflow: hidden; background: var(--placeholder); }
.door-media img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; transition: transform .7s ease; }
.door:hover .door-media img { transform: scale(1.03); }
.door h2 { font-family: var(--serif); font-weight: 400; font-size: 28px; margin-top: 16px; }
.door:hover h2 { font-style: italic; }
.door p { font-size: 14px; color: var(--muted); margin-top: 6px; line-height: 1.55; max-width: 34ch; }
.door .more { display: inline-block; margin-top: 12px; font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; font-weight: 400; color: var(--ink); }
#porte { scroll-margin-top: calc(var(--nav-h) + 16px); }

/* chiamata all'azione in fondo alle sezioni */
.section-cta { margin-top: 72px; padding-top: 40px; border-top: 0.5px solid var(--line); max-width: 640px; }
.section-cta h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(24px, 3vw, 32px); line-height: 1.2; }
.section-cta p { color: var(--muted); margin: 12px 0 24px; line-height: 1.6; }
.btn {
  display: inline-block; background: var(--ink); color: var(--paper); text-decoration: none;
  font-size: 12.5px; font-weight: 400; letter-spacing: .1em; text-transform: uppercase; padding: 14px 24px;
  transition: opacity .2s;
}
.btn:hover { opacity: .8; }
.btn-link { margin-left: 20px; font-size: 13px; text-decoration: underline; text-underline-offset: 4px; }
.empty { font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--muted); max-width: 520px; line-height: 1.6; }

/* ── STORIA ── */
.story-text { max-width: 620px; margin-bottom: 48px; }
.story-text p { font-size: 16.5px; line-height: 1.8; margin-bottom: 16px; }
.video { position: relative; aspect-ratio: 16/9; margin-bottom: 12px; background: #000; }
.video iframe, .video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ── PLACEHOLDER IMMAGINI ── */
.ph {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: var(--placeholder); color: var(--muted);
  font-size: 11px; letter-spacing: .1em; text-transform: uppercase; text-align: center; padding: 16px;
}
.ph[hidden] { display: none; }

/* ── GRIGLIA PROGETTI ── */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 40px 24px; }
.card { text-decoration: none; display: block; }
.card-media { position: relative; aspect-ratio: 3/2; overflow: hidden; background: var(--placeholder); }
.card-media img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; transition: transform .6s ease; }
.card:hover .card-media img { transform: scale(1.03); }
.card-title { font-family: var(--serif); font-size: 18px; font-weight: 400; margin-top: 14px; }
.card:hover .card-title { font-style: italic; }
.card-desc { font-size: 13.5px; color: var(--muted); margin-top: 4px; line-height: 1.5; }

/* ── PAGINA PROGETTO ── */
.back { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; font-weight: 400; display: inline-block; margin-bottom: 28px; }
.back:hover { text-decoration: underline; text-underline-offset: 4px; }
.gallery { columns: 3 280px; column-gap: 12px; }
.gallery button {
  display: block; width: 100%; margin-bottom: 12px; break-inside: avoid;
  border: 0; padding: 0; background: var(--placeholder); cursor: zoom-in; position: relative;
}
.gallery button img { width: 100%; height: auto; }
.gallery button.missing { aspect-ratio: 4/5; }
.project-nav { display: flex; justify-content: space-between; gap: 24px; margin-top: 56px; padding-top: 20px; border-top: 0.5px solid var(--line); }
.project-nav a { text-decoration: none; font-family: var(--serif); font-size: 17px; }
.project-nav a small { display: block; font-family: var(--sans); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.project-nav a:last-child { text-align: right; margin-left: auto; }
.project-nav a:hover { font-style: italic; }

/* ── LIGHTBOX ── */
.lightbox {
  position: fixed; inset: 0; z-index: 500; background: rgba(12,12,12,.96);
  display: flex; align-items: center; justify-content: center;
}
.lightbox[hidden] { display: none; }
.lightbox img { max-width: calc(100vw - 160px); max-height: calc(100vh - 100px); object-fit: contain; }
.lb-btn {
  position: absolute; background: none; border: 0; color: #e8e5df; cursor: pointer;
  font-family: var(--sans); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; padding: 16px;
}
.lb-btn:hover { color: #fff; }
.lb-close { top: 8px; right: 12px; }
.lb-prev { left: 8px; top: 50%; transform: translateY(-50%); font-size: 28px; }
.lb-next { right: 8px; top: 50%; transform: translateY(-50%); font-size: 28px; }
.lb-count { position: absolute; bottom: 18px; left: 0; right: 0; text-align: center; color: #a9a59d; font-size: 12px; letter-spacing: .1em; }

/* ── CHI SONO ── */
.about { display: grid; grid-template-columns: 300px 1fr; gap: 64px; align-items: start; max-width: 940px; }
.about-photo { aspect-ratio: 3/4; position: relative; overflow: hidden; background: var(--placeholder); }
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.about-text p { font-size: 16px; line-height: 1.8; margin-bottom: 18px; max-width: 560px; }
.about-text p.lead { font-family: var(--serif); font-size: 20px; line-height: 1.55; }
.cta {
  display: inline-block; margin-top: 12px; font-family: var(--serif); font-size: 18px; font-style: italic;
  text-decoration: none; border-bottom: 0.5px solid var(--ink); padding-bottom: 2px;
}
.cta:hover { opacity: .6; }

/* ── CONTATTI ── */
.contact-mail { font-family: var(--serif); font-size: clamp(22px, 3vw, 32px); text-decoration: none; border-bottom: 0.5px solid var(--ink); word-break: break-all; }
.contact-mail:hover { font-style: italic; }
.contact-meta { margin-top: 28px; font-size: 14px; color: var(--muted); line-height: 1.7; }

/* ── SOCIAL ── */
.social { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
.social a { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; }
.social a:hover { opacity: .6; }
.social svg { width: 18px; height: 18px; fill: currentColor; flex-shrink: 0; }
.social svg.stroke { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.social.labeled { margin-top: 36px; gap: 28px; }
.social.labeled a { font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; font-weight: 400; }

/* ── FOOTER ── */
.site-footer {
  border-top: 0.5px solid var(--line);
  padding: 20px var(--gutter);
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
  font-size: 12px; color: var(--muted);
}

/* ── RESPONSIVE ── */
@media (max-width: 1100px) {
  .nav-links { display: none; }
  .menu-toggle { display: flex; }
}
@media (max-width: 820px) {
  :root { --gutter: 20px; --nav-h: 58px; }
  .wrap { padding: 32px var(--gutter) 48px; }
  .manifesto { padding: 56px var(--gutter) 48px; }
  .hello { grid-template-columns: 1fr; gap: 32px; padding: 24px var(--gutter) 56px; min-height: 0; }
  .hello-photo { max-width: 420px; }
  .doors { grid-template-columns: 1fr; gap: 40px; }
  .door-media { aspect-ratio: 4/3; }
  .btn-link { display: block; margin: 16px 0 0; }
  .grid { grid-template-columns: 1fr; gap: 32px; }
  .about { grid-template-columns: 1fr; gap: 32px; }
  .about-photo { max-width: 360px; }
  .gallery { columns: 1; }
  .lightbox img { max-width: 100vw; max-height: calc(100vh - 120px); }
  .lb-prev, .lb-next { top: auto; bottom: 4px; transform: none; }
  .project-nav { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* luogo e zona di lavoro (pagine servizio e contatti) */
.zona { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 400; margin: -20px 0 40px; }
.gallery button img { width: 100%; height: auto; }
.card-media img, .door-media img, .hello-photo img { height: 100%; }

/* ── PAGINE SERVIZIO: testo intervallato da foto ── */
.svc-hero { position: relative; max-width: 1400px; margin: 0 auto 8px; padding: 0 var(--gutter); }
.svc-hero img { width: 100%; height: auto; aspect-ratio: 21/9; object-fit: cover; object-position: center 40%; display: block; }
.svc-block { display: grid; grid-template-columns: minmax(260px, 5fr) 7fr; gap: 56px; align-items: center; padding: 72px 0; border-bottom: 0.5px solid var(--line); }
.svc-block.flip .svc-text { order: 2; }
.svc-text h2, .svc-stories h2, .svc-faq h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(24px, 2.6vw, 32px); line-height: 1.2; margin-bottom: 18px; }
.svc-text p { font-size: 16.5px; line-height: 1.8; margin-bottom: 14px; max-width: 46ch; }
.svc-photos { display: grid; gap: 12px; }
.svc-photos.n2 { grid-template-columns: 1fr 1fr; align-items: start; }
.svc-photos figure { position: relative; margin: 0; overflow: hidden; background: var(--placeholder); }
.svc-photos img { width: 100%; height: auto; display: block; }
.svc-photos.n2 img { aspect-ratio: 4/5; object-fit: cover; }
.svc-stories { padding: 72px 0 0; }
.svc-stories .card-title { font-family: var(--serif); font-size: 18px; font-weight: 400; margin-top: 14px; }
.svc-faq { padding: 72px 0 0; max-width: 720px; }
.svc-faq details { border-top: 0.5px solid var(--line); padding: 18px 0; }
.svc-faq details:last-child { border-bottom: 0.5px solid var(--line); }
.svc-faq summary { cursor: pointer; font-family: var(--serif); font-size: 19px; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.svc-faq summary::-webkit-details-marker { display: none; }
.svc-faq summary::after { content: '+'; font-family: var(--sans); font-weight: 300; font-size: 22px; line-height: 1; }
.svc-faq details[open] summary::after { content: '–'; }
.svc-faq details p { margin-top: 12px; font-size: 16px; line-height: 1.75; color: var(--ink); }
/* segnaposto da completare: visibile solo finché c'è */
.todo { background: #e9dfb8; color: #4a3f10 !important; padding: 10px 14px; font-size: 14px !important; border-left: 3px solid #b8962e; font-style: normal; }
@media (max-width: 820px) {
  .svc-hero img { aspect-ratio: 4/3; }
  .svc-block { grid-template-columns: 1fr; gap: 28px; padding: 48px 0; }
  .svc-block.flip .svc-text { order: 0; }
}
.svc-photos.n1 img { max-height: 620px; object-fit: cover; }

/* ── foto più grandi, intere (non tagliate) e cliccabili ── */
.zoom { display: block; width: 100%; border: 0; padding: 0; background: none; cursor: zoom-in; }
.zoom img { transition: opacity .2s; }
.zoom:hover img { opacity: .92; }
.svc-hero img { aspect-ratio: auto; max-height: 86vh; object-fit: contain; width: auto; max-width: 100%; margin: 0 auto; }
.svc-block { grid-template-columns: minmax(240px, 4fr) 8fr; }
.svc-photos.n2 img { aspect-ratio: auto; object-fit: initial; }
.svc-photos.n1 img { max-height: 86vh; object-fit: contain; width: auto; max-width: 100%; margin: 0 auto; }
.gallery { columns: 2 420px; column-gap: 16px; }
.gallery button { margin-bottom: 16px; }
.card-media { aspect-ratio: auto; }
.card-media img { height: auto; object-fit: initial; }
.grid { align-items: start; }
@media (max-width: 820px) { .svc-block { grid-template-columns: 1fr; } .gallery { columns: 1; } }

/* due foto affiancate: stessa altezza, nessun taglio */
.svc-photos.n2 { display: flex; gap: 12px; align-items: flex-start; }
.svc-photos.n2 figure { min-width: 0; }
@media (max-width: 520px) { .svc-photos.n2 { flex-direction: column; } .svc-photos.n2 figure { flex: none !important; width: 100%; } }

/* ══ IMPAGINAZIONE EDITORIALE: foto grandi intervallate dal testo ══ */
.wide { max-width: 1600px; margin: 0 auto; padding: 0 var(--gutter); }
.flow { display: flex; flex-direction: column; gap: 16px; }
.flow .row { display: flex; gap: 16px; }
.flow figure { margin: 0; min-width: 0; position: relative; background: var(--placeholder); }
.flow .single figure { width: 100%; }
.flow .single.tall { justify-content: center; }
.flow .single.tall figure { width: auto; background: none; }
.flow .single.tall img { max-height: 94vh; width: auto; max-width: 100%; }
.flow img { display: block; width: 100%; height: auto; }
.flow .zoom { cursor: zoom-in; }
.chapter { padding-top: 120px; }
.chapter-text { max-width: 640px; margin: 0 auto 56px; text-align: center; }
.chapter-text h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 3.4vw, 44px); line-height: 1.15; margin-bottom: 20px; }
.chapter-text p { font-size: 17px; line-height: 1.85; margin: 0 auto 14px; max-width: 54ch; }
.chapter-text .todo { text-align: left; }
.wide > .flow:first-child { margin-top: 16px; }
.svc-stories { padding-top: 120px; }
@media (max-width: 820px) {
  .wide { padding: 0; }
  .flow, .flow .row { gap: 6px; }
  .flow .row.pair { flex-direction: column; }
  .flow .row.pair figure { flex: none !important; width: 100%; }
  .chapter { padding-top: 72px; }
  .chapter-text { padding: 0 var(--gutter); margin-bottom: 32px; text-align: left; }
  .svc-stories { padding-top: 72px; }
}

/* ogni riga di foto sta tutta nello schermo: larghezza massima legata all'altezza della finestra */
.flow .row { width: 100%; margin: 0 auto; }
@media (max-width: 820px) { .flow .row { max-width: none !important; } }

/* ══ LE STORIE COME UN LIBRO ══ */
.svc-stories h2 { text-align: center; }
.book { max-width: 1240px; margin: 0 auto; outline: none; perspective: 1800px; }
.book-page {
  display: grid; grid-template-columns: 1.15fr 1fr; min-height: min(68vh, 680px);
  background: #d9d5cd; box-shadow: 0 1px 0 rgba(0,0,0,.04), 0 18px 40px -24px rgba(0,0,0,.35);
  position: relative; transform-origin: left center;
}
/* piega centrale del libro */
.book-page::after {
  content: ''; position: absolute; top: 0; bottom: 0; left: 53.5%; width: 48px; transform: translateX(-50%);
  background: linear-gradient(90deg, rgba(0,0,0,0) 0%, rgba(0,0,0,.10) 45%, rgba(0,0,0,.16) 50%, rgba(255,255,255,.12) 55%, rgba(0,0,0,0) 100%);
  pointer-events: none;
}
.book-photo { display: flex; align-items: center; justify-content: center; padding: 40px; position: relative; }
.book-photo img { max-width: 100%; max-height: calc(min(68vh, 680px) - 80px); width: auto; height: auto; display: block; box-shadow: 0 6px 18px -10px rgba(0,0,0,.45); }
.book-photo .ph { position: static; width: 100%; height: 100%; min-height: 300px; }
.book-text { display: flex; flex-direction: column; justify-content: center; padding: 56px 64px; }
.book-num { font-family: var(--serif); font-size: 15px; letter-spacing: .08em; color: var(--muted); }
.book-num span { opacity: .7; }
.book-text h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(30px, 3.6vw, 48px); line-height: 1.1; margin: 18px 0 14px; }
.book-desc { font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--muted); line-height: 1.55; margin-bottom: 8px; max-width: 32ch; }
.book-text .cta { align-self: flex-start; margin-top: 22px; }
.book-nav { display: flex; align-items: center; justify-content: center; gap: 28px; margin-top: 28px; }
.book-nav button {
  width: 52px; height: 52px; border-radius: 50%; border: 0.5px solid var(--ink); background: none; cursor: pointer;
  font-size: 20px; color: var(--ink); transition: background .2s, color .2s;
}
.book-nav button:hover { background: var(--ink); color: var(--paper); }
.book-count { font-family: var(--serif); font-size: 16px; min-width: 56px; text-align: center; }
/* girare pagina */
.turn-out-next { animation: outNext .3s ease-in forwards; }
.turn-out-prev { animation: outPrev .3s ease-in forwards; }
.turn-in-next  { animation: inNext .42s ease-out; }
.turn-in-prev  { animation: inPrev .42s ease-out; }
@keyframes outNext { to { opacity: 0; transform: rotateY(-14deg) translateX(-3%); } }
@keyframes outPrev { to { opacity: 0; transform: rotateY(14deg) translateX(3%); } }
@keyframes inNext  { from { opacity: 0; transform: rotateY(10deg) translateX(3%); } to { opacity: 1; transform: none; } }
@keyframes inPrev  { from { opacity: 0; transform: rotateY(-10deg) translateX(-3%); } to { opacity: 1; transform: none; } }
@media (max-width: 820px) {
  .book-page { grid-template-columns: 1fr; min-height: 0; }
  .book-page::after { display: none; }
  .book-photo { padding: 20px 20px 0; }
  .book-photo img { max-height: 62vh; }
  .book-text { padding: 24px 24px 32px; }
}
.book-page[hidden] { display: none; }

/* capitoli: più spazio al testo */
.chapter-text { max-width: 680px; }
.chapter-text p { font-size: 17.5px; }
.chapter.text-only .chapter-text { margin-bottom: 0; }
.chapter.text-only + .chapter { padding-top: 96px; }

/* home: riga per il cliente, tre porte, bio sotto */
.hello-lead { font-family: var(--serif); font-style: italic; font-size: clamp(19px, 1.8vw, 23px); color: var(--muted); line-height: 1.5; margin: -8px 0 32px; max-width: 30ch; }
.doors-btn { display: flex; flex-direction: column; border-top: 0.5px solid var(--line); max-width: 480px; }
.btn-door { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 18px 0; border-bottom: 0.5px solid var(--line); text-decoration: none; }
.btn-door span { font-family: var(--serif); font-size: 26px; }
.btn-door small { font-size: 13px; color: var(--muted); text-align: right; }
.btn-door span::after { content: ' →'; font-size: 20px; opacity: 0; transition: opacity .2s, margin .2s; }
.btn-door:hover span { font-style: italic; }
.btn-door:hover span::after { opacity: 1; }
.hello-bio { max-width: 680px; margin: 0 auto; padding: 24px var(--gutter) 72px; text-align: center; }
.hello-bio h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 3.2vw, 40px); margin-bottom: 24px; }
.hello-bio p { font-size: 17.5px; line-height: 1.85; margin-bottom: 14px; }
.hello-bio .cta { margin-top: 16px; }
@media (max-width: 820px) { .hello-bio { text-align: left; padding-bottom: 72px; } .btn-door small { max-width: 50%; } }

/* ── Offerta ritratto ── */
.offer-wrap { padding: 0 var(--gutter) 120px; }
.offer { max-width: 560px; margin: 0 auto; padding: 40px; border: 0.5px solid var(--ink); text-align: center; }
.wrap .offer { margin-top: 72px; }
.offer-label { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.offer h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(26px, 3vw, 36px); margin: 10px 0 14px; }
.offer-text { line-height: 1.7; margin-bottom: 18px; }
.offer-price { font-family: var(--serif); font-size: 30px; margin-bottom: 24px; }
.offer-price small { display: block; font-family: var(--sans); font-size: 13px; color: var(--muted); margin-top: 4px; }
@media (max-width: 820px) { .offer-wrap { padding: 0 20px 72px; } .offer { padding: 32px 20px; } }
.offer-gift { font-family: var(--serif); font-style: italic; font-size: 18px; line-height: 1.5; margin: -4px 0 22px; }
.offer-actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 16px 0; }
@media (max-width: 820px) { .offer-actions { flex-direction: column; } .offer .btn-link { margin: 0; } }
.footer-clienti { font-size: 13px; text-decoration: underline; text-underline-offset: 4px; margin-left: auto; margin-right: 24px; }
.clienti-note { margin-top: 40px; padding-top: 24px; border-top: 0.5px solid var(--line); color: var(--muted); font-size: 15px; }
.clienti-note a { color: var(--ink); text-underline-offset: 4px; }
@media (max-width: 820px) { .footer-clienti { margin: 0; } }
